小编Phi*_*hil的帖子

元组与字典差异

有人可以解释一下元组和字典之间存在的主要区别是什么以及何时在Swift中使用哪些?

ios swift

28
推荐指数
2
解决办法
2万
查看次数

斯威夫特"专业化"崩溃

下面是我的一个应用程序中发生崩溃的堆栈跟踪.我不知道如何修复它并不总是发生?请帮忙 :)

它与Swift Generics有关吗?

    Thread : Crashed: com.apple.main-thread
0  MyApp                         0x1000f4f5c specialized FriendsTableViewController.tableView(UITableView, cellForRowAtIndexPath : NSIndexPath) -> UITableViewCell (FriendsTableViewController.swift)
1  MyApp                         0x1000f1f60 @objc FriendsTableViewController.tableView(UITableView, cellForRowAtIndexPath : NSIndexPath) -> UITableViewCell (FriendsTableViewController.swift)
2  UIKit                          0x1867ad31c -[UITableView _createPreparedCellForGlobalRow:withIndexPath:willDisplay:] + 692
3  UIKit                          0x1867ad484 -[UITableView _createPreparedCellForGlobalRow:willDisplay:] + 80
4  UIKit                          0x18679c9b8 -[UITableView _updateVisibleCellsNow:isRecursive:] + 2824
5  UIKit                          0x186539208 -[UITableView _setNeedsVisibleCellsUpdate:withFrames:] + 240
6  UIKit                          0x1865390d0 -[UITableView _rectChangedWithNewSize:oldSize:] + 996
7  UIKit                          0x186546df4 -[UITableView setBounds:] + 256
8  UIKit                          0x18647a2bc -[UIScrollView setContentOffset:] + 424
9 …
Run Code Online (Sandbox Code Playgroud)

generics crash ios swift

7
推荐指数
1
解决办法
3907
查看次数

标签 统计

ios ×2

swift ×2

crash ×1

generics ×1