From 1e41c151f6edfba69037c854a5cb7abc18bb55e7 Mon Sep 17 00:00:00 2001 From: Alan Kinnaman Date: Tue, 14 Jun 2016 00:17:08 -0700 Subject: Suppress warning when dequeueing subclasses (#5244) When using a subclass of `MGLAnnotationView` or `MGLAnnotationImage`, the following warning occurs: `Incompatible pointer types initializing 'MyClassName *' with an expression of type 'MGLAnnotationView * _Nullable'` This change eliminates the warning and matches Apple's implementation of `UITableViewCell`. --- platform/ios/src/MGLMapView.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'platform') diff --git a/platform/ios/src/MGLMapView.h b/platform/ios/src/MGLMapView.h index 09142c4093..1319228c1a 100644 --- a/platform/ios/src/MGLMapView.h +++ b/platform/ios/src/MGLMapView.h @@ -965,7 +965,7 @@ IB_DESIGNABLE @return An annotation image object with the given identifier, or `nil` if no such object exists in the reuse queue. */ -- (nullable MGLAnnotationImage *)dequeueReusableAnnotationImageWithIdentifier:(NSString *)identifier; +- (nullable __kindof MGLAnnotationImage *)dequeueReusableAnnotationImageWithIdentifier:(NSString *)identifier; /** Returns a reusable annotation view object associated with its identifier. @@ -981,7 +981,7 @@ IB_DESIGNABLE @return An annotation view object with the given identifier, or `nil` if no such object exists in the reuse queue. */ -- (nullable MGLAnnotationView *)dequeueReusableAnnotationViewWithIdentifier:(NSString *)identifier; +- (nullable __kindof MGLAnnotationView *)dequeueReusableAnnotationViewWithIdentifier:(NSString *)identifier; #pragma mark Managing Annotation Selections -- cgit v1.2.1