我正在为 ios 9 开发一个应用程序。因为我更新到 7.1 版本我有这个错误:命令失败由于信号:分段错误:11
查看代码,我发现这段代码导致了这个错误:
func mapView(mapView: MKMapView, viewForAnnotation annotation: MKAnnotation) -> MKAnnotationView? {
if !(annotation is ADBaseAnnotation){
print("No es ADBaseAnnotation",terminator:"\n")
return nil
}
var anView = mapView.dequeueReusableAnnotationViewWithIdentifier((annotation as! ADBaseAnnotation).getReuseId())
if let normal = annotation as? NormalParking {
//anView = normal.getAnnotationView(annotation, reuseIdentifier: normal.getReuseId())
} else if let hightlight = annotation as? HightLightParking{
//anView = hightlight.getAnnotationView(annotation, reuseIdentifier: hightlight.getReuseId())
}
return anView
}
该错误是由注释行引起的。请帮忙