The App I am current working on for some time now with no build errors has, since upgrading to xCode 4, been giving me an incompatible type warning for the last line of this code…
locationManager = [[CLLocationManager alloc] init];
locationManager.desiredAccuracy = kCLLocationAccuracyNearestTenMeters;
locationManager.delegate = self;
The funny thing about it is that after a clean and build, xCodes reports no issues. However, if I go to the class containing this code the build error suddenly appears and remains until I do a clean again.
the actual warning is…
warning: Semantic Issue: Incompatible pointer types assigning to ‘id’ from ‘Class’
CLLocationmanager works fine and my delegate methods are getting called so everything appears to be working properly. I would like to get rid of this warning. Should I just ignore it?
I think you should file a bug report with Apple and until they do something about it I guess all you can do is ignore it.