我正在尝试在我的ios应用程序中使用自定义segue,当我预先形成segue时,它总是返回"警告:无法加载任何Objective-C类信息。这将显着降低可用类型信息的质量。"以及" EXC_BAD_ACCESS(代码= 2,地址= 0x7fff504faff8)"这似乎是某种记忆警告,但我不确定为什么。
这是自定义segue代码,它似乎在一个空白项目中工作,但不在我的工作中,我似乎无法找出上述错误的含义...
之前有没有人见过这种错误? (我在这里的搜索没有返回任何与我所看到的相同的东西) - 我还包括了下面的堆栈跟踪的一部分。
private func animateGrowScale() {
let toViewController = destinationViewController
let fromViewController = sourceViewController
let containerView = fromViewController.view.superview
let originalCenter = fromViewController.view.center
toViewController.view.transform = CGAffineTransformMakeScale(0.05, 0.05)
toViewController.view.center = originalCenter
containerView?.addSubview(toViewController.view)
UIView.animateWithDuration(0.5, delay: 0.0, options: UIViewAnimationOptions.CurveEaseInOut, animations: {
toViewController.view.transform = CGAffineTransformMakeScale(1.0, 1.0)
}, completion: { finished in
let fromVC = self.sourceViewController
let toVC = self.destinationViewController
fromVC.presentViewController(toVC, animated: false, completion: nil)
})
}
堆栈追踪:
* thread #1: tid = 0x1f0b0b, 0x000000011142e23e libobjc.A.dylib`objc::DenseMapBase<objc::DenseMap<DisguisedPtr<objc_object>, unsigned long, true, objc::DenseMapInfo<DisguisedPtr<objc_object> > >, DisguisedPtr<objc_object>, unsigned long, objc::DenseMapInfo<DisguisedPtr<objc_object> >, true>::find(DisguisedPtr<objc_object> const&) + 4, queue = 'com.apple.main-thread', stop reason = EXC_BAD_ACCESS (code=2, address=0x7fff504faff8)
frame #0: 0x000000011142e23e libobjc.A.dylib`objc::DenseMapBase<objc::DenseMap<DisguisedPtr<objc_object>, unsigned long, true, objc::DenseMapInfo<DisguisedPtr<objc_object> > >, DisguisedPtr<objc_object>, unsigned long, objc::DenseMapInfo<DisguisedPtr<objc_object> >, true>::find(DisguisedPtr<objc_object> const&) + 4
frame #1: 0x000000011142c71d libobjc.A.dylib`objc_object::sidetable_tryRetain() + 75
frame #2: 0x000000011142bb75 libobjc.A.dylib`weak_read_no_lock + 99
frame #3: 0x000000011142c4c6 libobjc.A.dylib`objc_loadWeakRetained + 104
frame #4: 0x000000011142c4f2 libobjc.A.dylib`objc_loadWeak + 15
frame #5: 0x000000010fdb575e QuartzCore`CALayerGetContext + 47
frame #6: 0x000000010ff98461 UIKit`__windowForView + 103
frame #7: 0x0000000110089308 UIKit`-[UIViewController nextResponder] + 1002
frame #8: 0x000000011010323c UIKit`-[UIResponder _containedInAbsoluteResponderChain] + 24
frame #9: 0x0000000110103254 UIKit`-[UIResponder _containedInAbsoluteResponderChain] + 48
frame #10: 0x0000000110103254 UIKit`-[UIResponder _containedInAbsoluteResponderChain] + 48
frame #11: 0x000000010ffa77b3 UIKit`-[UIView(Internal) _containedInAbsoluteResponderChain] + 60
frame #12: 0x000000010ffa77b3 UIKit`-[UIView(Internal) _containedInAbsoluteResponderChain] + 60
frame #13: 0x000000010ffa77b3 UIKit`-[UIView(Internal) _containedInAbsoluteResponderChain] + 60