summaryrefslogtreecommitdiff
path: root/platform
diff options
context:
space:
mode:
authorJustin R. Miller <incanus@codesorcery.net>2015-09-03 14:55:28 -0700
committerJustin R. Miller <incanus@codesorcery.net>2015-09-04 09:16:26 -0700
commitcb730d3973431909d349b02c829e54e031ea6571 (patch)
tree9bd917bc32a2369ef60b29d3868d3a237e951124 /platform
parent790e8a345c5d0f1afe583db642b986917ba404f8 (diff)
downloadqtlocation-mapboxgl-cb730d3973431909d349b02c829e54e031ea6571.tar.gz
`assert() -> NSAssert()` for user-facing annotation API
Diffstat (limited to 'platform')
-rw-r--r--platform/ios/MGLMapView.mm10
1 files changed, 5 insertions, 5 deletions
diff --git a/platform/ios/MGLMapView.mm b/platform/ios/MGLMapView.mm
index f3c1785d8e..959f294f07 100644
--- a/platform/ios/MGLMapView.mm
+++ b/platform/ios/MGLMapView.mm
@@ -1910,7 +1910,7 @@ CLLocationCoordinate2D MGLLocationCoordinate2DFromLatLng(mbgl::LatLng latLng)
for (id <MGLAnnotation> annotation in annotations)
{
- assert([annotation conformsToProtocol:@protocol(MGLAnnotation)]);
+ NSAssert([annotation conformsToProtocol:@protocol(MGLAnnotation)], @"annotation should conform to MGLAnnotation");
if ([annotation isKindOfClass:[MGLMultiPoint class]])
{
@@ -2082,7 +2082,7 @@ CLLocationCoordinate2D MGLLocationCoordinate2DFromLatLng(mbgl::LatLng latLng)
for (id <MGLAnnotation> annotation in annotations)
{
- assert([annotation conformsToProtocol:@protocol(MGLAnnotation)]);
+ NSAssert([annotation conformsToProtocol:@protocol(MGLAnnotation)], @"annotation should conform to MGLAnnotation");
NSDictionary *infoDictionary = [self.annotationIDsByAnnotation objectForKey:annotation];
annotationIDsToRemove.push_back([[infoDictionary objectForKey:MGLAnnotationIDKey] unsignedIntValue]);
@@ -2107,7 +2107,7 @@ CLLocationCoordinate2D MGLLocationCoordinate2DFromLatLng(mbgl::LatLng latLng)
{
for (id <MGLOverlay> overlay in overlays)
{
- assert([overlay conformsToProtocol:@protocol(MGLOverlay)]);
+ NSAssert([overlay conformsToProtocol:@protocol(MGLOverlay)], @"overlay should conform to MGLOverlay");
}
[self addAnnotations:overlays];
@@ -2122,7 +2122,7 @@ CLLocationCoordinate2D MGLLocationCoordinate2DFromLatLng(mbgl::LatLng latLng)
{
for (id <MGLOverlay> overlay in overlays)
{
- assert([overlay conformsToProtocol:@protocol(MGLOverlay)]);
+ NSAssert([overlay conformsToProtocol:@protocol(MGLOverlay)], @"overlay should conform to MGLOverlay");
}
[self removeAnnotations:overlays];
@@ -2144,7 +2144,7 @@ CLLocationCoordinate2D MGLLocationCoordinate2DFromLatLng(mbgl::LatLng latLng)
id <MGLAnnotation> firstAnnotation = selectedAnnotations[0];
- assert([firstAnnotation conformsToProtocol:@protocol(MGLAnnotation)]);
+ NSAssert([firstAnnotation conformsToProtocol:@protocol(MGLAnnotation)], @"annotation should conform to MGLAnnotation");
if ([firstAnnotation isKindOfClass:[MGLMultiPoint class]]) return;