├── .DS_Store ├── .gitignore ├── No-response ├── README.md └── Xcode-Storyboard.md ├── README-EN.md ├── README.md ├── SUMMARY.md ├── Xcode-Error-Code ├── .DS_Store ├── Console │ ├── .DS_Store │ ├── Not-universally-unbranched │ │ ├── .DS_Store │ │ ├── Cannot-convert-value-of-type-'String?'-to-expected-argument-type.md.md │ │ ├── Could-not-cast-value-of-type-'UITableViewCell'-to-'.'.md │ │ ├── Instance-member-cannot-be-used-on-type-''.md │ │ ├── README.md │ │ └── Redundant-conformance-of ''-to-protocol-'' │ │ │ ├── '()-> ()'-is-not-convertible-to-Bool.md │ │ │ ├── .DS_Store │ │ │ └── Redundant-conformance-of-''-to-protocol.md │ ├── README.md │ └── Universal-branching │ │ ├── .DS_Store │ │ ├── README.md │ │ └── libcabidylib │ │ ├── Terminating-app-due-to-uncaught-exception.md │ │ └── libcabidylib.md ├── README.md └── Swift-Compiler │ ├── .DS_Store │ ├── README.md │ ├── Swift-Compiler-Error │ ├── .DS_Store │ ├── Consecutive-statements-on-a-line-must-be-separated-by-‘;’.md │ ├── Generic-Swift-Compile-Error-with-Branch │ │ ├── Expected-expression.md │ │ ├── README.md │ │ └── Use-of-undeclared.md │ ├── Parameter-requires-an-explicit-type.md │ ├── README.md │ └── Type-'ViewController'-does-not-conform-to-protocol.md │ └── Swift-Compiler-Warning │ ├── README.md │ └── String-literal-is-unused.md └── assets ├── 102112555517509.png └── w49aZ.png /.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FelixXiong/Xcode-Error-Collection/ce8e98140557254744c2ba0e9323875147556363/.DS_Store -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Node rules: 2 | ## Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files) 3 | .grunt 4 | 5 | ## Dependency directory 6 | ## Commenting this out is preferred by some people, see 7 | ## https://docs.npmjs.com/misc/faq#should-i-check-my-node_modules-folder-into-git 8 | node_modules 9 | 10 | # Book build output 11 | _book 12 | 13 | # eBook build output 14 | *.epub 15 | *.mobi 16 | *.pdf -------------------------------------------------------------------------------- /No-response/README.md: -------------------------------------------------------------------------------- 1 | # 操作无反应 2 | 3 | 以下是关于操作无反应时出现的问题以及解决方式。 4 | 5 | 格式: 6 | 7 | # 在某位置中操作(Heading1) 8 | 9 | ## 操作无反应(Heading2) 10 | 11 | **参考链接(Paragraph-bold)**这里的参考链接为搜索引擎出现的排名前几位结果(当然,不算广告) 12 | 13 | 平台(Paragraph) 14 | 15 | [参考链接(Paragraph-Insert Link)](https://www.gitbook.com/book/felixxiong/learn-swift-study-note/edit#) 16 | 17 | > 引用(Paragraph-Blockquote) 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /No-response/Xcode-Storyboard.md: -------------------------------------------------------------------------------- 1 | # Xcode Storyboard 2 | 3 | ## 按住ctrl至代码区没有反应没有弹出可选择的IBAction或是IBOutlets。 4 | 5 | 检查 storyboard 的class 是否绑定了对应的viewController。 6 | 7 | -------------------------------------------------------------------------------- /README-EN.md: -------------------------------------------------------------------------------- 1 | # Xcode Error Collection 2 | 3 | 4 | 5 | On the way to development, you will always encounter various kinds of errors. There are swift and Xcode. 6 | In the future development, it is convenient to look through the search for answers. 7 | 8 | # What it is 9 | 10 | As a college student who started iOS development and has more ideas, 11 | 12 | At present, self-study development will encounter various kinds of errors in the process of developing the functions. When solving problems, it is necessary to find suitable links in the network. 13 | 14 | At present, almost all the same problems exist on major platforms that already exist and will be incorporated in this book. 15 | 16 | After solving some problems, we can consider collecting them. Not only can we have a lot of sense of accomplishment when we look back, we can also help more developers who have encountered this problem, and hope that you can all walk on the road to development. Some detours. 17 | 18 | # Process 19 | 20 | At first it was to make a reminder list of the errors he had encountered. I think there are many developers, problems encountered in the past, and pits that have been stamped on them. 21 | 22 | At the same time, because each person's output has a different platform, he wants to create a Repo on GitHub to collect and organize. 23 | 24 | This is currently included in the Repository, except I wrote it myself. 25 | 26 | There are also some friends who are learning Swif and making independent development. 27 | 28 | # content 29 | 30 | The contents of this collection mainly include two parts 31 | 32 | ## No response 33 | 34 | No response to operation: The location, problems, and solutions to occur when the operation is not responding. 35 | Currently only Storyboard. 36 | 37 | ## Xcode Error Codes 38 | 39 | The Xcode error code includes the error code that appears when the error code of the **Swift compiler** and the **console** is wrong and the solution. 40 | 41 | ## Website 42 | 43 | (names not listed in order) 44 | 45 | China: [Segmentfault](https://segmentfault.com),[Short Book](https://www.jianshu.com/), [Nuggets] (https://juejin.im/timeline) , [CSDN](http://blog.csdn.net) , [Blog Park](https://www.cnblogs.com) 46 | 47 | Non-China: [Starkoverflow](https://stackoverflow.com) 48 | 49 | At present, according to the increase in the number of reported errors, it has gradually increased. 50 | 51 | # Expectations 52 | 53 | > Having encountered a problem, first look at the collection for any such errors. 54 | > 55 | > When you encounter errors, don't panic and don't be discouraged. You're not alone. 56 | 57 | # Current member 58 | 59 | Currently joining members: 60 | 61 | [FelixXiong](https://github.com/FelixXiong): Students who love to experience products, design point of view, self-study iOS development 62 | 63 | [LicaGao](https://github.com/LicaGao): A pseudo-programmer senior dog who knows a bit about iOS fur 64 | 65 | [Jaketo](https://bladderofculture.blogspot.com): Self-paced iOS students 66 | 67 | ## Hope to have your contribution 68 | 69 | First of all if you are an iOS developer or will be, then this error collection can help you save time in solving problems. 70 | 71 | If you are interested in learning about the Xcode error specification and are familiar with and follow the specifications explicitly mentioned in the book, I hope you join together. 72 | 73 | Hopefully this error collection can have more developers involved, and also welcome friends who are interested to share. 74 | 75 | Welcome to Watch, Star, Fork, and most importantly Pull Request: Contribution errors and solutions. 76 | 77 | # WeChat Group 78 | 79 | Interested friends can enter the "WeChat group" issue to comment, join WeChat group, conduct interactions and exchanges with us, and standardize the update of the wrong format. 80 | 81 | ## Contact me 82 | 83 | If you have a better idea, you are welcome to contact me. 84 | 85 | Weibo: [@ guys who love tossing mobile phones](https://weibo.com/5210076054/profile?rightmod=1&wvr=6&mod=personinfo&is_all=1) 86 | 87 | WeChat: accisd235 88 | 89 | Twitter: [@holothemixet(FelixXiong)](https://twitter.com/holothemixet) 90 | 91 | Telegram: [@FelixXiong](t.me/FelixXiong) 92 | 93 | # From a collection of common mistakes: 94 | 95 | * [Xcode Error Collection](README.md) 96 | * [No response](No-response/README.md) 97 | * [Xcode StoryBoard](No-response/Xcode-Storyboard.md) 98 | * [Xcode Error Code](Xcode-Error-Code/README.md) 99 | * [Swift-Compiler](Xcode-Error-Code/Swift-Compiler/README.md) 100 | * [Swift Compiler Warning](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Warning/README.md) 101 | * [String literal is unused](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Warning/String-literal-is-unused.md) 102 | * [Swift Compiler Error](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/README.md) 103 | * [Type 'ViewController' does not conform to protocol](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Type-'ViewController'-does-not-conform-to-protocol.md) 104 | * [Generic wift Compile Error with Branch](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Generic-Swift-Compile-Error-with-Branch/README.md) 105 | * [Use of undeclared](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Generic-Swift-Compile-Error-with-Branch/Use-of-undeclared.md) 106 | * [Expected expression](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Generic-Swift-Compile-Error-with-Branch/Expected-expression.md) 107 | * [Console](Xcode-Error-Code/Console/README.md) 108 | * [Universal branching](Xcode-Error-Code/Console/Universal-branching/README.md) 109 | * [libc++abi.dylib:](Xcode-Error-Code/Console/Universal-branching/libcabidylib/libcabidylib.md) 110 | * [Terminating app due to uncaught exception ''](Xcode-Error-Code/Console/Universal-branching/libcabidylib/Terminating-app-due-to-uncaught-exception.md) 111 | 112 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Xcode报错集合 2 | 3 | 4 | 5 | 在开发的路上,总会遇到各种各样的错误,有swift的,有Xcode的。 6 | 在今后的开发中,就可以通过查阅进行答案的寻找,很方便。 7 | 8 | # 由来 9 | 10 | 作为一名入门iOS开发以及有着比较多的想法的大学生, 11 | 12 | 目前自学开发,在开发功能的过程中会遇到各种各样的错误,解决问题时需要在网络里寻找各种各样的链接。 13 | 14 | 目前在已经有的各大平台上的几乎是相同的问题,将在此书中进行收纳集合。 15 | 16 | 解决了一些问题之后,便考虑可以将它们收集起来,不仅回过头看可以有很多成就感,还可以帮到更多遇到此问题的开发者们,也希望各位在开发的路上都可以少走一些弯路。 17 | 18 | # 过程 19 | 20 | 起初是将自己遇到的报错制作一个备忘清单,想到目前国内有很多的开发者、之前遇见的问题、踩过的坑有很多, 21 | 22 | 同时由于每个人的输出有着不同的平台,便在想GitHub上制作一个Repo,进行集合与整理。 23 | 24 | 这个Repository里目前收录的除了我自己写的, 25 | 26 | 还有一些认识的正在学习Swift以及制作独立开发的朋友们。 27 | 28 | # 内容 29 | 30 | 本集合内容主要包括两部分 31 | 32 | ## 操作无反应 33 | 34 | 操作无反应:关于操作无反应时出现的位置、问题以及解决方式。 35 | 目前仅有Storyboard。 36 | 37 | ## Xcode错误代码 38 | 39 | Xcode错误代码其中包括**Swift编译器**以及**控制台**的错误代码错时出现的错误代码以及解决方式。 40 | 41 | ## 网站 42 | 43 | (排名不分先后) 44 | 45 | 国内:[Segmentfault](https://segmentfault.com)、[简书](https://www.jianshu.com/)、[掘金](https://juejin.im/timeline)、[CSDN](http://blog.csdn.net) 、[博客园](https://www.cnblogs.com) 46 | 47 | 国外:[Starkoverflow](https://stackoverflow.com) 48 | 49 | 目前根据报错问题的增加,陆续增加中。 50 | 51 | # 期望 52 | 53 | > 遇到了问题,先看看集合中是否有这样的错误,这里都整理好了。 54 | > 55 | > 在遇到错误的时候,不要慌,不要气馁,你不是一个人。 56 | 57 | # 目前成员 58 | 59 | 目前加入成员: 60 | 61 | [FelixXiong](https://github.com/FelixXiong):热爱体验产品,会点设计,自学iOS开发的大学生 62 | 63 | [LicaGao](https://github.com/LicaGao):懂点iOS皮毛的伪程序员大四狗 64 | 65 | [Jaketo](https://bladderofculture.blogspot.com):自学iOS开发的大学生 66 | 67 | [Jinya](http://jinya.me):iOS开发者,目前维护[短信卫士](https://itunes.apple.com/cn/app/%E7%9F%AD%E4%BF%A1%E5%8D%AB%E5%A3%AB/id1317407948?mt=8) 68 | 69 | [TianZhen](http://www.tianzhen.tech):全栈培训讲师,打字很快 70 | 71 | [iPersestence](https://github.com/we11cheng):三年工作萌新一枚,学习swift中 72 | 73 | [丰泽](https://www.jianshu.com/u/fb8c7b98d40b):独立应用 圆视界 开发者 74 | 75 | ## 希望有你的贡献 76 | 77 | 首先如果你是一名iOS开发者或者即将是,那么这个报错集合可以帮到你节约在解决问题上的时间。 78 | 79 | 如果你有兴趣、了解Xcode报错的规范以及熟悉并遵守书中的明确提到的规范,也希望你一起加入。 80 | 81 | 希望此报错集合可以有更多的开发者参与,同时也欢迎有兴趣的朋友一起来分享。 82 | 83 | 欢迎Watch、Star、Fork和最重要的Pull Request:贡献错误以及解决方案。 84 | 85 | # 微信群 86 | 87 | 有兴趣的朋友可以进入“加入微信群”issue进行评论,加入微信群,进行与我们的互动与交流,以及错误格式的标准化更新。 88 | 89 | ## 联系我 90 | 91 | 如果有更好的想法,也欢迎联系我。 92 | 93 | 微博:[@爱折腾手机的伙子](https://weibo.com/5210076054/profile?rightmod=1&wvr=6&mod=personinfo&is_all=1) 94 | 95 | 微信:accisd235 96 | 97 | Twitter:[@holothemixet(FelixXiong)](https://twitter.com/holothemixet) 98 | 99 | Telegram:[@FelixXiong](t.me/FelixXiong) 100 | 101 | 102 | # 摘自集合里的常见错误: 103 | 104 | * [操作无反应](No-response/README.md) 105 | * [Xcode StoryBoard](No-response/Xcode-Storyboard.md) 106 | * [Xcode错误代码](Xcode-Error-Code/README.md) 107 | * [Swift Compiler Warning](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Warning/README.md) 108 | * [String literal is unused](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Warning/String-literal-is-unused.md) 109 | * [Swift Compiler Error](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/README.md) 110 | * [Type 'ViewController' does not conform to protocol](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Type-'ViewController'-does-not-conform-to-protocol.md) 111 | * [Consecutive statements on a line must be separated by ‘;’](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Consecutive-statements-on-a-line-must-be-separated-by-‘;’.md) 112 | * [Parameter requires an explicit type](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Parameter-requires-an-explicit-type.md) 113 | * [通用的具有分支的Swift编译报错](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Generic-Swift-Compile-Error-with-Branch/README.md) 114 | * [Use of undeclared](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Generic-Swift-Compile-Error-with-Branch/Use-of-undeclared.md) 115 | * [Expected expression](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Generic-Swift-Compile-Error-with-Branch/Expected-expression.md) 116 | * [控制台](Xcode-Error-Code/Console/README.md) 117 | * [通用的具有分支的错误代码](Xcode-Error-Code/Console/Universal-branching/README.md) 118 | * [libc++abi.dylib:](Xcode-Error-Code/Console/Universal-branching/libcabidylib/libcabidylib.md) 119 | * [Terminating app due to uncaught exception ''](Xcode-Error-Code/Console/Universal-branching/libcabidylib/Terminating-app-due-to-uncaught-exception.md) 120 | -------------------------------------------------------------------------------- /SUMMARY.md: -------------------------------------------------------------------------------- 1 | # Summary 2 | 3 | * [Xcode报错集合](README.md) 4 | * [操作无反应](No-response/README.md) 5 | * [Xcode StoryBoard](No-response/Xcode-Storyboard.md) 6 | * [Xcode错误代码](Xcode-Error-Code/README.md) 7 | * [Swift编译器](Xcode-Error-Code/Swift-Compiler/README.md) 8 | * [Swift Compiler Warning](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Warning/README.md) 9 | * [String literal is unused](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Warning/String-literal-is-unused.md) 10 | * [Swift Compiler Error](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/README.md) 11 | * [Type 'ViewController' does not conform to protocol](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Type-'ViewController'-does-not-conform-to-protocol.md) 12 | * [Consecutive statements on a line must be separated by ‘;’](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Consecutive-statements-on-a-line-must-be-separated-by-‘;’.md) 13 | * [Parameter requires an explicit type](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Parameter-requires-an-explicit-type.md) 14 | * [通用的具有分支的Swift编译报错](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Generic-Swift-Compile-Error-with-Branch/README.md) 15 | * [Use of undeclared](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Generic-Swift-Compile-Error-with-Branch/Use-of-undeclared.md) 16 | * [Expected expression](Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Generic-Swift-Compile-Error-with-Branch/Expected-expression.md) 17 | * [控制台](Xcode-Error-Code/Console/README.md) 18 | * [通用的具有分支的错误代码](Xcode-Error-Code/Console/Universal-branching/README.md) 19 | * [libc++abi.dylib:](Xcode-Error-Code/Console/Universal-branching/libcabidylib/libcabidylib.md) 20 | * [Terminating app due to uncaught exception ''](Xcode-Error-Code/Console/Universal-branching/libcabidylib/Terminating-app-due-to-uncaught-exception.md) 21 | * [不通用的不具有分支的错误代码](Xcode-Error-Code/Console/Not-universally-unbranched/README.md) 22 | * [Instance member cannot be used on type](Xcode-Error-Code/Console/Not-universally-unbranched/Instance-member-cannot-be-used-on-type.md) 23 | * [Cannot convert value of type 'String?' to expected argument type ''](Xcode-Error-Code/Console/Not-universally-unbranched/Cannot-convert-value-of-type-'String?'-to-expected-argument-type-''.md)(未链接) 24 | * [Could not cast value of type 'UITableViewCell'\(\) to '.'](Xcode-Error-Code/Console/Not-universally-unbranched/Could-not-cast-value-of-type-'UITableViewCell'-to-'.'.md ) 25 | * [Redundant conformance of '' to protocol ''](Xcode-Error-Code/Console/Not-universally-unbranched/Redundant-conformance-of-''-to-protocol.md)(未链接) 26 | * ['\(\) -> \(\)' is not convertible to 'Bool'](Xcode-Error-Code/Console/Not-universally-unbranched/Redundant-conformance-of-''-to-protocol/'()-> ()'-is-not-convertible-to-Bool.md) 27 | 28 | -------------------------------------------------------------------------------- /Xcode-Error-Code/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FelixXiong/Xcode-Error-Collection/ce8e98140557254744c2ba0e9323875147556363/Xcode-Error-Code/.DS_Store -------------------------------------------------------------------------------- /Xcode-Error-Code/Console/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FelixXiong/Xcode-Error-Collection/ce8e98140557254744c2ba0e9323875147556363/Xcode-Error-Code/Console/.DS_Store -------------------------------------------------------------------------------- /Xcode-Error-Code/Console/Not-universally-unbranched/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FelixXiong/Xcode-Error-Collection/ce8e98140557254744c2ba0e9323875147556363/Xcode-Error-Code/Console/Not-universally-unbranched/.DS_Store -------------------------------------------------------------------------------- /Xcode-Error-Code/Console/Not-universally-unbranched/Cannot-convert-value-of-type-'String?'-to-expected-argument-type.md.md: -------------------------------------------------------------------------------- 1 | Cannot convert value of type 'String?' to expected argument type '' 2 | 3 | **参考链接** 4 | 5 | Stackoverflow 6 | 7 | [Cannot convert value of type \`\[String: String?\]\` to expected argument type \`\[String: String!\]\`](https://stackoverflow.com/questions/33164264/cannot-convert-value-of-type-string-string-to-expected-argument-type-str) 8 | 9 | -------------------------------------------------------------------------------- /Xcode-Error-Code/Console/Not-universally-unbranched/Could-not-cast-value-of-type-'UITableViewCell'-to-'.'.md: -------------------------------------------------------------------------------- 1 | # Could not cast value of type 'UITableViewCell' to '.' 2 | -------------------------------------------------------------------------------- /Xcode-Error-Code/Console/Not-universally-unbranched/Instance-member-cannot-be-used-on-type-''.md: -------------------------------------------------------------------------------- 1 | # Instance member cannot be used on type 2 | 3 | **参考链接** 4 | 5 | 简书 6 | 7 | [报错:instance member '某某' cannot be used on type '...'](https://www.jianshu.com/p/15d0e127957a) 8 | 9 | Stackoverflow 10 | 11 | [Instance member cannot be used on type](https://stackoverflow.com/questions/32351343/instance-member-cannot-be-used-on-type) 12 | 13 | [What's wrong here: Instance member cannot be used on type \[duplicate\]](https://stackoverflow.com/questions/32693150/whats-wrong-here-instance-member-cannot-be-used-on-type) 14 | 15 | ## 可能报错的情况 16 | 17 | **1.漏行** 18 | 19 | 报错位置:最下方三行cell显示文字处 20 | 21 | ```swift 22 | override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { 23 | let cell = tableView.dequeueReusableCell(withIdentifier: "ExampleTableViewCell", for: indexPath) as! WillLearnTableViewCell 24 | 25 | //之前漏掉了这一行,添加即可 26 | let ExampleList = ExampleArray[indexPath.row] 27 | 28 | cell.Title.text = ExampleList.TitleLabel 29 | cell.Description.text = ExampleList.DesLabel 30 | cell.Notes.text = ExampleList.NotesLabel 31 | ``` 32 | 33 | 解决方法:添加行 34 | 35 | ```swift 36 | let ExampleList = ExampleArray[indexPath.row] 37 | ``` 38 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /Xcode-Error-Code/Console/Not-universally-unbranched/README.md: -------------------------------------------------------------------------------- 1 | # 错误问题不通用的不具有分支的错误代码 2 | 3 | 自本页起,为错误问题不具有分支的错误代码。 4 | 5 | 解释为: 6 | 7 | > 在报错位置(包括但不限于控制台,例如AppDelegate.swift)中,出现的不通用的报错代码,其没有分支。 8 | 9 | 更新的格式规范: 10 | 11 | # 错误代码(Heading1) 12 | 13 | **参考链接(Paragraph-bold)**这里的参考链接为搜索引擎出现的排名前几位结果(当然,不算广告) 14 | 15 | 平台(Paragraph) 16 | 17 | [参考链接(Paragraph-Insert Link)](https://www.gitbook.com/book/felixxiong/learn-swift-study-note/edit#) 18 | 19 | > 引用(Paragraph-Blockquote) 20 | 21 | 在自己出现的错误代码情况下,为以下格式: 22 | 23 | 位置在正常序号之下。 24 | 25 | ## 可能报错的情况(Heading2) 26 | 27 | **序号.出现此问题的情况说明(Paragraph-bold)** 28 | 29 | **报错位置(Paragraph-bold)** 30 | 31 | **解决方法(Paragraph-bold)** 32 | 33 | **参考链接(Paragraph-bold)** 34 | 35 | 平台(Paragraph) 36 | 37 | [参考链接(Paragraph-Insert Link)](https://www.gitbook.com/book/felixxiong/learn-swift-study-note/edit#) 38 | 39 | > 引用(Paragraph-Blockquote) 40 | 41 | 42 | 43 | -------------------------------------------------------------------------------- /Xcode-Error-Code/Console/Not-universally-unbranched/Redundant-conformance-of ''-to-protocol-''/'()-> ()'-is-not-convertible-to-Bool.md: -------------------------------------------------------------------------------- 1 | # '\(\) -> \(\)' is not convertible to 'Bool' 2 | 3 | 此问题与**Redundant conformance of '' to protocol ''联动** 4 | 5 | Stackoverflow 6 | 7 | [\(\_\) -> bool not convertible to \(\)](https://stackoverflow.com/questions/36022545/bool-not-convertible-to) 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /Xcode-Error-Code/Console/Not-universally-unbranched/Redundant-conformance-of ''-to-protocol-''/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FelixXiong/Xcode-Error-Collection/ce8e98140557254744c2ba0e9323875147556363/Xcode-Error-Code/Console/Not-universally-unbranched/Redundant-conformance-of ''-to-protocol-''/.DS_Store -------------------------------------------------------------------------------- /Xcode-Error-Code/Console/Not-universally-unbranched/Redundant-conformance-of ''-to-protocol-''/Redundant-conformance-of-''-to-protocol.md: -------------------------------------------------------------------------------- 1 | # Redundant conformance of '' to protocol '' 2 | 3 | **参考链接** 4 | 5 | Stackoverflow 6 | 7 | [Swift : Redundant conformance of Viewcontroller to protocol UIGestureRecognizerDelegate](https://stackoverflow.com/questions/32540452/swift-redundant-conformance-of-viewcontroller-to-protocol-uigesturerecognizerd) 8 | 9 | 可能报错的情况 10 | 11 | **1.各种ViewController不正确** 12 | 13 | 报错位置:\#import下方class 类名处 14 | 15 | ```swift 16 | class ListTableViewController: UITableViewController,UITableViewDataSource,UITableViewDelegate{ 17 | ``` 18 | 19 | 解决方法:应为ViewController(以下简称VC),实际则输入为TableViewViewController,VC文件开头class处修改对则正常。 20 | 21 | ```swift 22 | class ListViewController: UIViewController,UITableViewDataSource,UITableViewDelegate{ 23 | ``` 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /Xcode-Error-Code/Console/README.md: -------------------------------------------------------------------------------- 1 | # 错误代码 2 | 3 | 以下是关于Xcode报错时出现的错误代码以及解决方式以及格式规范。 4 | 5 | 包含部分: 6 | 7 | # 错误问题通用的具有分支的错误代码 8 | 9 | 解释为: 10 | 11 | > 在报错位置(包括但不限于控制台,例如AppDelegate.swift)中,出现的通用报错代码,以及其的分支。 12 | 13 | 更新的格式规范为章节页。 14 | 15 | # 对于错误问题不具有分支的错误代码 16 | 17 | 解释为: 18 | 19 | > 在报错位置(包括但不限于控制台,例如AppDelegate.swift)中,出现的不通用的报错代码,其没有分支。 20 | 21 | 更新的格式规范为章节页。 22 | 23 | -------------------------------------------------------------------------------- /Xcode-Error-Code/Console/Universal-branching/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FelixXiong/Xcode-Error-Collection/ce8e98140557254744c2ba0e9323875147556363/Xcode-Error-Code/Console/Universal-branching/.DS_Store -------------------------------------------------------------------------------- /Xcode-Error-Code/Console/Universal-branching/README.md: -------------------------------------------------------------------------------- 1 | # 错误问题通用的具有分支的错误代码 2 | 3 | 自本页起,为错误问题通用的具有分支的错误代码。 4 | 5 | 解释为: 6 | 7 | > 在报错位置(包括但不限于控制台,例如AppDelegate.swift)中,出现的通用报错代码,以及其的分支。 8 | 9 | 更新的格式规范: 10 | 11 | # 错误代码(Heading1) 12 | 13 | 报错位置 14 | 15 | ## 序号.错误代码(分支)(Heading2) 16 | 17 | ### 序号.序号.错误代码(分支)(Heading3) 18 | 19 | **出现此问题的情况说明:(Paragraph-bold)** 20 | 21 | 序号.出现此问题的情况说明 22 | 23 | **解决方法(Paragraph-bold)** 24 | 25 | 序号.解决方法 26 | 27 | **参考链接(Paragraph-bold)** 28 | 29 | 序号 30 | 31 | 平台(Paragraph) 32 | 33 | [参考链接(Paragraph-Insert Link)](https://www.gitbook.com/book/felixxiong/learn-swift-study-note/edit#) 34 | 35 | > 引用(Paragraph-Blockquote) 36 | 37 | 在自己未出现可是网络查询结果出现的情况下,为以下格式: 38 | 39 | 位置在正常序号之下。 40 | 41 | ## \*.可能报错的情况(Heading2) 42 | 43 | ## 序号.错误代码(分支)(Heading2)(可能不了解) 44 | 45 | ### 序号.序号.错误代码(分支)(Heading3)(可能不了解) 46 | 47 | **序号.出现此问题的情况说明(Paragraph-bold)** 48 | 49 | **情况说明(Paragraph-bold)**(可能不了解,但多为控制台) 50 | 51 | **解决方法(Paragraph-bold)**(一定要有解决方法,否则不更新) 52 | 53 | **参考链接(Paragraph-bold)** 54 | 55 | 平台(Paragraph) 56 | 57 | [参考链接(Paragraph-Insert Link)](https://www.gitbook.com/book/felixxiong/learn-swift-study-note/edit#)(为出现此问题的的链接) 58 | 59 | > 引用(Paragraph-Blockquote)(为出现此问题的原因) 60 | 61 | 62 | 63 | -------------------------------------------------------------------------------- /Xcode-Error-Code/Console/Universal-branching/libcabidylib/Terminating-app-due-to-uncaught-exception.md: -------------------------------------------------------------------------------- 1 | # Terminating app due to uncaught exception '' 2 | 3 | # reason: '-\[项目名称.项目(自定义)类名:\]: 4 | 5 | 报错位置:控制台 6 | 7 | ## 1.‘NSInvalidArgumentException' 8 | 9 | ### 1.2:unrecognized selector sent to instance : 10 | 11 | **出现此问题的情况说明:** 12 | 13 | 1:未设置代理 14 | 15 | 2.点按某个控件出现崩溃(crash) 16 | 17 | **解决步骤:** 18 | 19 | 1:设置代理(Delegate) 20 | 21 | 2.定位断点进行查看 22 | 23 | **参考链接:** 24 | 25 | 2: 26 | 27 | cnblogs 28 | 29 | [unrecognized selector sent to instance的定位](http://www.cnblogs.com/liuguanlei/p/4482327.html) 30 | 31 | > 在Xcode的菜单栏中选择Debug->Breakpoints->Create Symbolic Breakpoint点击后,会添加一个断点调试,弹出编辑框 32 | > 33 | > 在编辑框的Symbol中填写`-[NSObject(NSObject)doesNotRecognizeSelector:]`此方法签名,对于边看本博文边试验的同学来说,在复制方法签名后想粘贴的时候,发现Xcode中的编辑框不见了,此时右击刚才添加的那个断点,选择Edit Breakpoint即可。 34 | > 35 | > 运行代码,断点就会停留在导致崩溃的地方。 36 | 37 | ### 1.3.'Could not find a storyboard named 'Main' in bundle NSBundle </Users//Library/Developer/CoreSimulator/Devices//data/Containers/Bundle/Application//.app> \(loaded\)' 38 | 39 | **出现此问题的情况说明:** 40 | 41 | 删除Main.Storyboard之后再从文件夹复制上一个文件(没有选择添加文件) 42 | 43 | **解决步骤:** 44 | 45 | **参考链接:** 46 | 47 | cnblogs 48 | 49 | [Could not find a storyboard named 'Main' in bundle NSBundle](http://www.cnblogs.com/ygm900/p/3836580.html) 50 | 51 | > 1、删掉工程中main.storyboard 后要删除plist文件中对应的键值,否则会报如下错误: Could not find a storyboard named 'Main' in bundle NSBundle 52 | > 53 | > ![](/assets/102112555517509.png) 54 | > 55 | > 2、删除main.storyboard后,需要在AppDelegate.m中初始化一个window进行使用,否则应用程序没有window可用。\`\`\` 56 | > 57 | > ```swift 58 | > self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]] 59 | > ``` 60 | 61 | ### 1.4.'Could not load NIB in bundle: 'NSBundle </Users//Library/Developer/CoreSimulator/Devices//data/Containers/Bundle/Application//.app> \(loaded\)' with name 'Main'' 62 | 63 | **出现此问题的情况说明:** 64 | 65 | 删除Main.Storyboard之后再从文件夹复制上一个文件\(上一个文件\),重新添加上图中Info.plist键值 66 | 67 | **解决步骤:** 68 | 69 | **参考链接:** 70 | 71 | Starkoverflow 72 | 73 | [https://stackoverflow.com/questions/6827949/could-not-load-nib-in-bundle/6827988](https://stackoverflow.com/questions/6827949/could-not-load-nib-in-bundle/6827988) 74 | 75 | > You have to take care of two things : 76 | > 77 | > 1. this call assumes you have a file named 'ViewLecturer.xib' and not 'file.xib' 78 | > 2. make sure the file is included in the app bundle. Check that in the build phases > copy ressources to bundle. 79 | 80 | ## 2.'NSUnknownKeyException' 81 | 82 | ### 2.1.this class is not key value coding-compliant for the key' 83 | 84 | **出现此问题的情况说明:** 85 | 86 | 1:模拟器出现白屏 87 | 88 | 2:运行之后点击控件数次发生崩溃 89 | 90 | **解决步骤:** 91 | 92 | 1:检查是否有黄色的叹号的Outlets,进行删除。 93 | 94 | 2:去除更改过控件值之后的IBOutlet或者IBAction 95 | 96 | **参考链接:** 97 | 98 | CSDN 99 | 100 | [his class is not key value coding-compliant for the key](http://blog.csdn.net/menxu_work/article/details/8825664) 101 | 102 | > 一般此问题 都是由interface build与代码中IBOutlet的连接所引起的。 103 | > 104 | > 可能是在代码中对iboutlet的名称进行了修改,导致interface build中的连接失效. 105 | > 106 | > 如果在该viewcontroller连接的xib文件中没发现错误, 107 | > 108 | > 那就很可能是mainWindow.xib文件中存在问题, 109 | > 110 | > 本人遇到的问题是在mainWindow.xib的tabbarcontroller的某个tab的viewcontroller设置了loadfrom"\*\*.xib", 111 | > 112 | > 但忘了将其class设为对应的viewcontroller类了。 113 | > 114 | > 仔细检查自己的nib文件,清理、修正不正确的连接关系即可。 115 | 116 | Stackoverflow 117 | 118 | [libc++abi.dylib: terminating with uncaught exception of type NSException \(lldb\)](https://stackoverflow.com/questions/26442414/libcabi-dylib-terminating-with-uncaught-exception-of-type-nsexception-lldb) 119 | 120 | > CMYR - "his could also happen if you've wired up a button to an IBAction that doesn't exist anymore \(or has been renamed\)" 121 | > 122 | > If you're running into this problem make sure that you go to Main.storyboard, RIGHT click on the yellow box icon \(view controller\) at the top of the phone outline and DELETE the outlet\(s\) with yellow flags. 123 | > 124 | > What happens in instances like this is you probably named an action, then renamed it. You need to delete the old name and if that was the only issue will start right up in sim! 125 | 126 | ## \*.可能报错的情况 127 | 128 | **1.Controller在调用的时候声明成了局部变量,系统无法找到正确的 Controller.** 129 | 130 | **解决方法:不要把controller 写成局部变量。(不用xib,无所谓)** 131 | 132 | **参考链接** 133 | 134 | CSDN 135 | 136 | [http://blog.csdn.net/hong1595/article/details/39189923](https://www.gitbook.com/book/felixxiong/xcode/edit#) 137 | 138 | > 我的controller,在调用的时候声明成了局部变量,系统无法找到正确的 controller. 139 | 140 | **2.在修改从Storyboard拖拽的控件到swift文件中的控件(类名)时之前的IBOutlet和IBAction链接未去除.** 141 | 142 | 报错位置:控制台 143 | 144 | **解决方法:去除修改类名之前的IBOutlet和IBAction链接** 145 | 146 | 147 | 148 | -------------------------------------------------------------------------------- /Xcode-Error-Code/Console/Universal-branching/libcabidylib/libcabidylib.md: -------------------------------------------------------------------------------- 1 | # libc++abi.dylib: 2 | 3 | # terminating with uncaught exception of type NSException 4 | 5 | 报错位置:控制台 6 | 7 | # 1.Terminating app due to uncaught exception '' 8 | 9 | ### **该情况的具体分支可以点击Terminating app due to uncaught exception ''页面查看。** 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /Xcode-Error-Code/README.md: -------------------------------------------------------------------------------- 1 | # Xcode错误代码 2 | 3 | 关于Xcode报错时出现的错误代码以及解决方式以及格式规范。 4 | 5 | 包含部分: 6 | 7 | # swift编译器 8 | 9 | 解释为: 10 | 11 | > 制作代码中出现的错误为Swift编译器开头的错误。 12 | 13 | 更新的格式规范为章节页。 14 | 15 | # 控制台 16 | 17 | 解释为: 18 | 19 | > 此为在调试过程中,控制台内出现的报错问题。 20 | 21 | 更新的格式规范为章节页。 -------------------------------------------------------------------------------- /Xcode-Error-Code/Swift-Compiler/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FelixXiong/Xcode-Error-Collection/ce8e98140557254744c2ba0e9323875147556363/Xcode-Error-Code/Swift-Compiler/.DS_Store -------------------------------------------------------------------------------- /Xcode-Error-Code/Swift-Compiler/README.md: -------------------------------------------------------------------------------- 1 | # Swift编译器 2 | 3 | 以下是关于Xcode报错时出现的Swift编译器错误以及解决方式。 4 | 5 | 包含部分: 6 | 7 | # Swift Compiler Warning 8 | 9 | 更新的格式规范为章节页。 10 | 11 | # Swift Compiler Error 12 | 13 | 更新的格式规范为章节页。 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FelixXiong/Xcode-Error-Collection/ce8e98140557254744c2ba0e9323875147556363/Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/.DS_Store -------------------------------------------------------------------------------- /Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Consecutive-statements-on-a-line-must-be-separated-by-‘;’.md: -------------------------------------------------------------------------------- 1 | # Consecutive statements on a line must be separated by ‘;’ 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Generic-Swift-Compile-Error-with-Branch/Expected-expression.md: -------------------------------------------------------------------------------- 1 | # Expected expression 2 | 3 | **情况说明:模拟器出现白屏** 4 | 5 | 解决步骤:检查是否有黄色的叹号的Outlets,进行删除。 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Generic-Swift-Compile-Error-with-Branch/README.md: -------------------------------------------------------------------------------- 1 | # 通用的具有分支的Swift编译报错 2 | 3 | # 错误代码(Heading1) 4 | 5 | 报错位置 6 | 7 | ## 序号.错误代码(分支)(Heading2) 8 | 9 | **出现此问题的情况说明:(Paragraph-bold)** 10 | 11 | 序号.出现此问题的情况说明 12 | 13 | **解决方法(Paragraph-bold)** 14 | 15 | 序号.解决方法 16 | 17 | **参考链接(Paragraph-bold)** 18 | 19 | 序号 20 | 21 | 平台(Paragraph) 22 | 23 | [参考链接(Paragraph-Insert Link)](https://www.gitbook.com/book/felixxiong/learn-swift-study-note/edit#) 24 | 25 | > 引用(Paragraph-Blockquote) 26 | 27 | 在自己未出现可是网络查询结果出现的情况下,为以下格式: 28 | 29 | 位置在正常序号之下。 30 | 31 | ## \*.可能报错的情况(Heading2) 32 | 33 | ## 序号.错误代码(分支)(Heading2)(可能不了解) 34 | 35 | ### 序号.序号.错误代码(分支)(Heading3)(可能不了解) 36 | 37 | **序号.出现此问题的情况说明(Paragraph-bold)** 38 | 39 | **情况说明(Paragraph-bold)**(可能不了解,但多为控制台) 40 | 41 | **解决方法(Paragraph-bold)**(一定要有解决方法,否则不更新) 42 | 43 | **参考链接(Paragraph-bold)** 44 | 45 | 平台(Paragraph) 46 | 47 | [参考链接(Paragraph-Insert Link)](https://www.gitbook.com/book/felixxiong/learn-swift-study-note/edit#)(为出现此问题的的链接) 48 | 49 | > 引用(Paragraph-Blockquote)(为出现此问题的原因) 50 | 51 | 52 | 53 | -------------------------------------------------------------------------------- /Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Generic-Swift-Compile-Error-with-Branch/Use-of-undeclared.md: -------------------------------------------------------------------------------- 1 | # Use of undeclared 2 | 3 | ## type ‘indexPath’ 4 | 5 | ## identifier’,for’ 6 | 7 | **参考链接** 8 | 9 | ['Use of Unresolved Identifier' in Swift](https://stackoverflow.com/questions/28996730/use-of-unresolved-identifier-in-swift) 10 | 11 | > One possible issue is that your new class has a different Target or different Targets from the other one. 12 | > 13 | > For example, it might have a testing target while the other one doesn't. For this specific case, you have to include all of your classes in the testing target or none of them. 14 | 15 | ![](/assets/w49aZ.png) 16 | 17 | [https://learnappmaking.com/unresolved-identifier-understanding-xcode/](https://www.gitbook.com/book/felixxiong/xcode/edit#) 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Parameter-requires-an-explicit-type.md: -------------------------------------------------------------------------------- 1 | # Parameter requires an explicit type 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/README.md: -------------------------------------------------------------------------------- 1 | # Swift Compiler Error 2 | 3 | 更新的格式规范: 4 | 5 | # 错误代码(Heading1) 6 | 7 | **参考链接(Paragraph-bold)**这里的参考链接为搜索引擎出现的排名前几位结果(当然,不算广告) 8 | 9 | 平台(Paragraph) 10 | 11 | [参考链接(Paragraph-Insert Link)](https://www.gitbook.com/book/felixxiong/learn-swift-study-note/edit#) 12 | 13 | > 引用(Paragraph-Blockquote) 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Error/Type-'ViewController'-does-not-conform-to-protocol.md: -------------------------------------------------------------------------------- 1 | # Type 'WillLearnListViewController' does not conform to protocol 'UITableViewDataSource'Do you want to add protocol stubs? 2 | 3 | **参考链接** 4 | 5 | Stackoverflow 6 | 7 | [Type 'ViewController' does not conform to protocol 'UITableViewDataSource'](https://stackoverflow.com/questions/25581780/type-viewcontroller-does-not-conform-to-protocol-uitableviewdatasource) 8 | 9 | > You should implement all the required methods before the last`}`, but you have written them outside of the UIViewController. 10 | > 11 | > Also, you need to change the func for number of lines. 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Warning/README.md: -------------------------------------------------------------------------------- 1 | # Swift Compiler Warning 2 | 3 | 更新的格式规范: 4 | 5 | # 错误代码(Heading1) 6 | 7 | **参考链接(Paragraph-bold)**这里的参考链接为搜索引擎出现的排名前几位结果(当然,不算广告) 8 | 9 | 平台(Paragraph) 10 | 11 | [参考链接(Paragraph-Insert Link)](https://www.gitbook.com/book/felixxiong/learn-swift-study-note/edit#) 12 | 13 | > 引用(Paragraph-Blockquote) 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /Xcode-Error-Code/Swift-Compiler/Swift-Compiler-Warning/String-literal-is-unused.md: -------------------------------------------------------------------------------- 1 | # String literal is unused 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /assets/102112555517509.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FelixXiong/Xcode-Error-Collection/ce8e98140557254744c2ba0e9323875147556363/assets/102112555517509.png -------------------------------------------------------------------------------- /assets/w49aZ.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/FelixXiong/Xcode-Error-Collection/ce8e98140557254744c2ba0e9323875147556363/assets/w49aZ.png --------------------------------------------------------------------------------