From 256689a33d465e8909e9bc5883ee3340551c7dca Mon Sep 17 00:00:00 2001 From: Jason Wray Date: Wed, 17 Aug 2016 15:30:39 -0400 Subject: [ios, macos] Make Xcode 7.3 the minimum required version - Removes nullability shims for Xcode 6. - Removes MGLTypes.h from files where it was only being used for nullability support. - Accepts that `NS_SWIFT_NAME` is not fully supported by Xcode 7.2 and lower. - Adds documentation about Xcode 7.3 requirement. --- platform/darwin/src/MGLAccountManager.h | 2 -- platform/darwin/src/MGLAnnotation.h | 2 -- platform/darwin/src/MGLBackgroundStyleLayer.h | 1 - platform/darwin/src/MGLCircleStyleLayer.h | 1 - platform/darwin/src/MGLClockDirectionFormatter.h | 2 -- platform/darwin/src/MGLCompassDirectionFormatter.h | 2 -- platform/darwin/src/MGLCoordinateFormatter.h | 2 -- platform/darwin/src/MGLFeature.h | 2 -- platform/darwin/src/MGLFillStyleLayer.h | 1 - platform/darwin/src/MGLGeometry.h | 2 -- platform/darwin/src/MGLLineStyleLayer.h | 1 - platform/darwin/src/MGLMapCamera.h | 2 -- platform/darwin/src/MGLMultiPoint.h | 2 -- platform/darwin/src/MGLMultiPoint_Private.h | 1 - platform/darwin/src/MGLOfflineRegion.h | 2 -- platform/darwin/src/MGLOverlay.h | 2 -- platform/darwin/src/MGLPointAnnotation.h | 2 -- platform/darwin/src/MGLRasterStyleLayer.h | 1 - platform/darwin/src/MGLShape.h | 2 -- platform/darwin/src/MGLStyle.h | 4 ++-- platform/darwin/src/MGLStyleAttribute.mm | 2 ++ platform/darwin/src/MGLStyleAttributeValue.h | 2 -- platform/darwin/src/MGLStyleAttributeValue_Private.h | 1 - platform/darwin/src/MGLStyleLayer.h.ejs | 1 - platform/darwin/src/MGLStyleLayer.mm | 1 - platform/darwin/src/MGLSymbolStyleLayer.h | 1 - platform/darwin/src/MGLTypes.h | 10 ---------- platform/darwin/src/NSData+MGLAdditions.h | 2 -- platform/darwin/src/NSString+MGLAdditions.h | 2 -- platform/darwin/src/NSURL+MGLAdditions.h | 2 -- 30 files changed, 4 insertions(+), 56 deletions(-) (limited to 'platform/darwin') diff --git a/platform/darwin/src/MGLAccountManager.h b/platform/darwin/src/MGLAccountManager.h index 2a11b2869e..fe602aa210 100644 --- a/platform/darwin/src/MGLAccountManager.h +++ b/platform/darwin/src/MGLAccountManager.h @@ -1,7 +1,5 @@ #import -#import "MGLTypes.h" - NS_ASSUME_NONNULL_BEGIN /** diff --git a/platform/darwin/src/MGLAnnotation.h b/platform/darwin/src/MGLAnnotation.h index 7293aeec4f..4c8f600240 100644 --- a/platform/darwin/src/MGLAnnotation.h +++ b/platform/darwin/src/MGLAnnotation.h @@ -2,8 +2,6 @@ #import #import -#import "MGLTypes.h" - NS_ASSUME_NONNULL_BEGIN /** diff --git a/platform/darwin/src/MGLBackgroundStyleLayer.h b/platform/darwin/src/MGLBackgroundStyleLayer.h index 4b0fddeceb..8fa9abddec 100644 --- a/platform/darwin/src/MGLBackgroundStyleLayer.h +++ b/platform/darwin/src/MGLBackgroundStyleLayer.h @@ -1,7 +1,6 @@ // This file is generated. // Edit platform/darwin/scripts/generate-style-code.js, then run `make style-code-darwin`. -#import "MGLTypes.h" #import "MGLStyleAttributeValue.h" #import "MGLBaseStyleLayer.h" diff --git a/platform/darwin/src/MGLCircleStyleLayer.h b/platform/darwin/src/MGLCircleStyleLayer.h index eaab3b843d..c5a344d419 100644 --- a/platform/darwin/src/MGLCircleStyleLayer.h +++ b/platform/darwin/src/MGLCircleStyleLayer.h @@ -1,7 +1,6 @@ // This file is generated. // Edit platform/darwin/scripts/generate-style-code.js, then run `make style-code-darwin`. -#import "MGLTypes.h" #import "MGLStyleAttributeValue.h" #import "MGLBaseStyleLayer.h" diff --git a/platform/darwin/src/MGLClockDirectionFormatter.h b/platform/darwin/src/MGLClockDirectionFormatter.h index e467b20e06..ea427aa7b1 100644 --- a/platform/darwin/src/MGLClockDirectionFormatter.h +++ b/platform/darwin/src/MGLClockDirectionFormatter.h @@ -1,8 +1,6 @@ #import #import -#import "MGLTypes.h" - NS_ASSUME_NONNULL_BEGIN /** diff --git a/platform/darwin/src/MGLCompassDirectionFormatter.h b/platform/darwin/src/MGLCompassDirectionFormatter.h index c2a6e000fa..fde26ba42a 100644 --- a/platform/darwin/src/MGLCompassDirectionFormatter.h +++ b/platform/darwin/src/MGLCompassDirectionFormatter.h @@ -1,8 +1,6 @@ #import #import -#import "MGLTypes.h" - NS_ASSUME_NONNULL_BEGIN /** diff --git a/platform/darwin/src/MGLCoordinateFormatter.h b/platform/darwin/src/MGLCoordinateFormatter.h index 3759576d2a..909c1e8935 100644 --- a/platform/darwin/src/MGLCoordinateFormatter.h +++ b/platform/darwin/src/MGLCoordinateFormatter.h @@ -1,8 +1,6 @@ #import #import -#import "MGLTypes.h" - NS_ASSUME_NONNULL_BEGIN /** diff --git a/platform/darwin/src/MGLFeature.h b/platform/darwin/src/MGLFeature.h index 1ab587ede5..aec4223b12 100644 --- a/platform/darwin/src/MGLFeature.h +++ b/platform/darwin/src/MGLFeature.h @@ -5,8 +5,6 @@ #import "MGLPointAnnotation.h" #import "MGLShapeCollection.h" -#import "MGLTypes.h" - NS_ASSUME_NONNULL_BEGIN /** diff --git a/platform/darwin/src/MGLFillStyleLayer.h b/platform/darwin/src/MGLFillStyleLayer.h index 06a58b12bd..de5369a333 100644 --- a/platform/darwin/src/MGLFillStyleLayer.h +++ b/platform/darwin/src/MGLFillStyleLayer.h @@ -1,7 +1,6 @@ // This file is generated. // Edit platform/darwin/scripts/generate-style-code.js, then run `make style-code-darwin`. -#import "MGLTypes.h" #import "MGLStyleAttributeValue.h" #import "MGLBaseStyleLayer.h" diff --git a/platform/darwin/src/MGLGeometry.h b/platform/darwin/src/MGLGeometry.h index ca99eaf16f..5fc927697b 100644 --- a/platform/darwin/src/MGLGeometry.h +++ b/platform/darwin/src/MGLGeometry.h @@ -2,8 +2,6 @@ #import #import -#import "MGLTypes.h" - NS_ASSUME_NONNULL_BEGIN /** Defines the area spanned by an `MGLCoordinateBounds`. */ diff --git a/platform/darwin/src/MGLLineStyleLayer.h b/platform/darwin/src/MGLLineStyleLayer.h index 6f3472b0b3..812e759ebc 100644 --- a/platform/darwin/src/MGLLineStyleLayer.h +++ b/platform/darwin/src/MGLLineStyleLayer.h @@ -1,7 +1,6 @@ // This file is generated. // Edit platform/darwin/scripts/generate-style-code.js, then run `make style-code-darwin`. -#import "MGLTypes.h" #import "MGLStyleAttributeValue.h" #import "MGLBaseStyleLayer.h" diff --git a/platform/darwin/src/MGLMapCamera.h b/platform/darwin/src/MGLMapCamera.h index 4b50c32b2f..f6bff36280 100644 --- a/platform/darwin/src/MGLMapCamera.h +++ b/platform/darwin/src/MGLMapCamera.h @@ -2,8 +2,6 @@ #import #import -#import "MGLTypes.h" - NS_ASSUME_NONNULL_BEGIN /** diff --git a/platform/darwin/src/MGLMultiPoint.h b/platform/darwin/src/MGLMultiPoint.h index 2d6b327086..59d9cd9429 100644 --- a/platform/darwin/src/MGLMultiPoint.h +++ b/platform/darwin/src/MGLMultiPoint.h @@ -3,8 +3,6 @@ #import "MGLShape.h" -#import "MGLTypes.h" - NS_ASSUME_NONNULL_BEGIN /** diff --git a/platform/darwin/src/MGLMultiPoint_Private.h b/platform/darwin/src/MGLMultiPoint_Private.h index aa52a02fcb..dc39172723 100644 --- a/platform/darwin/src/MGLMultiPoint_Private.h +++ b/platform/darwin/src/MGLMultiPoint_Private.h @@ -1,7 +1,6 @@ #import "MGLMultiPoint.h" #import "MGLGeometry.h" -#import "MGLTypes.h" #import #import diff --git a/platform/darwin/src/MGLOfflineRegion.h b/platform/darwin/src/MGLOfflineRegion.h index cf98e253bd..fe0ab6cb7f 100644 --- a/platform/darwin/src/MGLOfflineRegion.h +++ b/platform/darwin/src/MGLOfflineRegion.h @@ -1,7 +1,5 @@ #import -#import "MGLTypes.h" - NS_ASSUME_NONNULL_BEGIN /** diff --git a/platform/darwin/src/MGLOverlay.h b/platform/darwin/src/MGLOverlay.h index ba03b19737..382305b444 100644 --- a/platform/darwin/src/MGLOverlay.h +++ b/platform/darwin/src/MGLOverlay.h @@ -4,8 +4,6 @@ #import "MGLAnnotation.h" #import "MGLGeometry.h" -#import "MGLTypes.h" - NS_ASSUME_NONNULL_BEGIN /** diff --git a/platform/darwin/src/MGLPointAnnotation.h b/platform/darwin/src/MGLPointAnnotation.h index 13afcab717..b552912f97 100644 --- a/platform/darwin/src/MGLPointAnnotation.h +++ b/platform/darwin/src/MGLPointAnnotation.h @@ -3,8 +3,6 @@ #import "MGLShape.h" -#import "MGLTypes.h" - NS_ASSUME_NONNULL_BEGIN /** diff --git a/platform/darwin/src/MGLRasterStyleLayer.h b/platform/darwin/src/MGLRasterStyleLayer.h index e666862339..b9deed8ff4 100644 --- a/platform/darwin/src/MGLRasterStyleLayer.h +++ b/platform/darwin/src/MGLRasterStyleLayer.h @@ -1,7 +1,6 @@ // This file is generated. // Edit platform/darwin/scripts/generate-style-code.js, then run `make style-code-darwin`. -#import "MGLTypes.h" #import "MGLStyleAttributeValue.h" #import "MGLBaseStyleLayer.h" diff --git a/platform/darwin/src/MGLShape.h b/platform/darwin/src/MGLShape.h index 40c92fc32d..ce9375c910 100644 --- a/platform/darwin/src/MGLShape.h +++ b/platform/darwin/src/MGLShape.h @@ -2,8 +2,6 @@ #import "MGLAnnotation.h" -#import "MGLTypes.h" - NS_ASSUME_NONNULL_BEGIN /** diff --git a/platform/darwin/src/MGLStyle.h b/platform/darwin/src/MGLStyle.h index a8b36ab0ca..3354d27a43 100644 --- a/platform/darwin/src/MGLStyle.h +++ b/platform/darwin/src/MGLStyle.h @@ -1,9 +1,9 @@ #import -#import "MGLTypes.h" - #import "MGLStyleLayer.h" +#import "MGLTypes.h" + @class MGLSource; NS_ASSUME_NONNULL_BEGIN diff --git a/platform/darwin/src/MGLStyleAttribute.mm b/platform/darwin/src/MGLStyleAttribute.mm index 38c212ddd4..8c51f80758 100644 --- a/platform/darwin/src/MGLStyleAttribute.mm +++ b/platform/darwin/src/MGLStyleAttribute.mm @@ -3,6 +3,8 @@ #import "MGLStyleAttributeValue_Private.h" #import "MGLStyleAttributeFunction_Private.h" +#import "MGLTypes.h" + @interface MGLStyleAttribute() @end diff --git a/platform/darwin/src/MGLStyleAttributeValue.h b/platform/darwin/src/MGLStyleAttributeValue.h index 31edccb14f..cd33923889 100644 --- a/platform/darwin/src/MGLStyleAttributeValue.h +++ b/platform/darwin/src/MGLStyleAttributeValue.h @@ -1,7 +1,5 @@ #import -#import "MGLTypes.h" - @protocol MGLStyleAttributeValue @optional @end \ No newline at end of file diff --git a/platform/darwin/src/MGLStyleAttributeValue_Private.h b/platform/darwin/src/MGLStyleAttributeValue_Private.h index 5fd51d09cf..3051f663d7 100644 --- a/platform/darwin/src/MGLStyleAttributeValue_Private.h +++ b/platform/darwin/src/MGLStyleAttributeValue_Private.h @@ -1,6 +1,5 @@ #import -#import "MGLTypes.h" #import "MGLStyleAttributeFunction_Private.h" #include diff --git a/platform/darwin/src/MGLStyleLayer.h.ejs b/platform/darwin/src/MGLStyleLayer.h.ejs index 629edba6c6..4ef28469f1 100644 --- a/platform/darwin/src/MGLStyleLayer.h.ejs +++ b/platform/darwin/src/MGLStyleLayer.h.ejs @@ -6,7 +6,6 @@ // This file is generated. // Edit platform/darwin/scripts/generate-style-code.js, then run `make style-code-darwin`. -#import "MGLTypes.h" #import "MGLStyleAttributeValue.h" #import "MGLBaseStyleLayer.h" diff --git a/platform/darwin/src/MGLStyleLayer.mm b/platform/darwin/src/MGLStyleLayer.mm index 6703226cba..43d98d62dc 100644 --- a/platform/darwin/src/MGLStyleLayer.mm +++ b/platform/darwin/src/MGLStyleLayer.mm @@ -1,5 +1,4 @@ #import "MGLStyleLayer.h" -#import "MGLTypes.h" #import "MGLStyleLayer_Private.h" #import "MGLMapView_Private.h" diff --git a/platform/darwin/src/MGLSymbolStyleLayer.h b/platform/darwin/src/MGLSymbolStyleLayer.h index 1f3568890b..371107226f 100644 --- a/platform/darwin/src/MGLSymbolStyleLayer.h +++ b/platform/darwin/src/MGLSymbolStyleLayer.h @@ -1,7 +1,6 @@ // This file is generated. // Edit platform/darwin/scripts/generate-style-code.js, then run `make style-code-darwin`. -#import "MGLTypes.h" #import "MGLStyleAttributeValue.h" #import "MGLBaseStyleLayer.h" diff --git a/platform/darwin/src/MGLTypes.h b/platform/darwin/src/MGLTypes.h index f63c602a53..bc1889c96c 100644 --- a/platform/darwin/src/MGLTypes.h +++ b/platform/darwin/src/MGLTypes.h @@ -2,16 +2,6 @@ #pragma once -#if !__has_feature(nullability) - #define NS_ASSUME_NONNULL_BEGIN - #define NS_ASSUME_NONNULL_END - #define nullable - #define nonnull - #define null_resettable - #define _Nullable - #define _Nonnull -#endif - #if TARGET_OS_IPHONE @class UIColor; #define MGLColor UIColor diff --git a/platform/darwin/src/NSData+MGLAdditions.h b/platform/darwin/src/NSData+MGLAdditions.h index 0c68c81f45..38af7961b6 100644 --- a/platform/darwin/src/NSData+MGLAdditions.h +++ b/platform/darwin/src/NSData+MGLAdditions.h @@ -1,7 +1,5 @@ #import -#import "MGLTypes.h" - NS_ASSUME_NONNULL_BEGIN @interface NSData (MGLAdditions) diff --git a/platform/darwin/src/NSString+MGLAdditions.h b/platform/darwin/src/NSString+MGLAdditions.h index 3001624d32..5b549affd5 100644 --- a/platform/darwin/src/NSString+MGLAdditions.h +++ b/platform/darwin/src/NSString+MGLAdditions.h @@ -1,7 +1,5 @@ #import -#import "MGLTypes.h" - NS_ASSUME_NONNULL_BEGIN @interface NSString (MGLAdditions) diff --git a/platform/darwin/src/NSURL+MGLAdditions.h b/platform/darwin/src/NSURL+MGLAdditions.h index 70fd79f064..9845a180db 100644 --- a/platform/darwin/src/NSURL+MGLAdditions.h +++ b/platform/darwin/src/NSURL+MGLAdditions.h @@ -1,7 +1,5 @@ #import -#import "MGLTypes.h" - NS_ASSUME_NONNULL_BEGIN @interface NSURL (MGLAdditions) -- cgit v1.2.1