From bc7155bfe247b7543e5f0ec9180f5bdb7d64c377 Mon Sep 17 00:00:00 2001 From: Jeremy Chiang Date: Tue, 1 May 2018 14:12:18 -0700 Subject: [PATCH] Fix all Xcode 9.3 warnings and bump version --- Bluejay.podspec | 2 +- Bluejay/Bluejay.xcodeproj/project.pbxproj | 6 ++- .../xcshareddata/xcschemes/Bluejay.xcscheme | 4 +- .../xcshareddata/IDEWorkspaceChecks.plist | 8 ++++ Bluejay/Bluejay/Info.plist | 2 +- Bluejay/Bluejay/Queue.swift | 2 +- Bluejay/Bluejay/Queueable.swift | 2 +- .../ScanHeartRateSensorsViewController.swift | 2 +- Bluejay/Pods/Pods.xcodeproj/project.pbxproj | 40 +++++++++++++++---- 9 files changed, 51 insertions(+), 17 deletions(-) create mode 100644 Bluejay/Bluejay.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist diff --git a/Bluejay.podspec b/Bluejay.podspec index 1f97b34..963c3c9 100644 --- a/Bluejay.podspec +++ b/Bluejay.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |spec| spec.name = 'Bluejay' - spec.version = '0.6.0' + spec.version = '0.6.1' spec.license = { type: 'MIT', file: 'LICENSE' } spec.homepage = 'https://github.com/steamclock/bluejay' spec.authors = { 'Jeremy Chiang' => 'jeremy@steamclock.com' } diff --git a/Bluejay/Bluejay.xcodeproj/project.pbxproj b/Bluejay/Bluejay.xcodeproj/project.pbxproj index 2356342..2cebed4 100644 --- a/Bluejay/Bluejay.xcodeproj/project.pbxproj +++ b/Bluejay/Bluejay.xcodeproj/project.pbxproj @@ -498,7 +498,7 @@ isa = PBXProject; attributes = { LastSwiftUpdateCheck = 0820; - LastUpgradeCheck = 0900; + LastUpgradeCheck = 0930; ORGANIZATIONNAME = "Steamclock Software"; TargetAttributes = { B8C70F741E1C22850006CF58 = { @@ -811,6 +811,7 @@ CLANG_WARN_BOOL_CONVERSION = YES; CLANG_WARN_COMMA = YES; CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; CLANG_WARN_DOCUMENTATION_COMMENTS = YES; CLANG_WARN_EMPTY_BODY = YES; @@ -818,6 +819,7 @@ CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INT_CONVERSION = YES; CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; @@ -870,6 +872,7 @@ CLANG_WARN_BOOL_CONVERSION = YES; CLANG_WARN_COMMA = YES; CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; CLANG_WARN_DOCUMENTATION_COMMENTS = YES; CLANG_WARN_EMPTY_BODY = YES; @@ -877,6 +880,7 @@ CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INT_CONVERSION = YES; CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; diff --git a/Bluejay/Bluejay.xcodeproj/xcshareddata/xcschemes/Bluejay.xcscheme b/Bluejay/Bluejay.xcodeproj/xcshareddata/xcschemes/Bluejay.xcscheme index 896a6dd..5b4a279 100644 --- a/Bluejay/Bluejay.xcodeproj/xcshareddata/xcschemes/Bluejay.xcscheme +++ b/Bluejay/Bluejay.xcodeproj/xcshareddata/xcschemes/Bluejay.xcscheme @@ -1,6 +1,6 @@ + + + + IDEDidComputeMac32BitWarning + + + diff --git a/Bluejay/Bluejay/Info.plist b/Bluejay/Bluejay/Info.plist index df80ae9..b1786cd 100644 --- a/Bluejay/Bluejay/Info.plist +++ b/Bluejay/Bluejay/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 0.6.0 + 0.6.1 CFBundleVersion $(CURRENT_PROJECT_VERSION) NSPrincipalClass diff --git a/Bluejay/Bluejay/Queue.swift b/Bluejay/Bluejay/Queue.swift index f3453d2..7532be1 100644 --- a/Bluejay/Bluejay/Queue.swift +++ b/Bluejay/Bluejay/Queue.swift @@ -231,7 +231,7 @@ extension Queue: ConnectionObserver { } } - func connected(_ peripheral: Peripheral) { + func connected(to peripheral: Peripheral) { update() } diff --git a/Bluejay/Bluejay/Queueable.swift b/Bluejay/Bluejay/Queueable.swift index 6d15abe..265d7dc 100644 --- a/Bluejay/Bluejay/Queueable.swift +++ b/Bluejay/Bluejay/Queueable.swift @@ -14,7 +14,7 @@ import CoreBluetooth */ protocol Queueable: class { - weak var queue: Queue? { get set } + var queue: Queue? { get set } /// The state of the operation in the queue. var state: QueueableState { get } diff --git a/Bluejay/BluejayDemo/ScanHeartRateSensorsViewController.swift b/Bluejay/BluejayDemo/ScanHeartRateSensorsViewController.swift index 686ea9b..d783726 100644 --- a/Bluejay/BluejayDemo/ScanHeartRateSensorsViewController.swift +++ b/Bluejay/BluejayDemo/ScanHeartRateSensorsViewController.swift @@ -159,7 +159,7 @@ extension ScanHeartRateSensorsViewController: ConnectionObserver { } } - func connected(_ peripheral: Peripheral) { + func connected(to peripheral: Peripheral) { debugPrint("Connected to \(peripheral)") } diff --git a/Bluejay/Pods/Pods.xcodeproj/project.pbxproj b/Bluejay/Pods/Pods.xcodeproj/project.pbxproj index 4993a22..feb5967 100644 --- a/Bluejay/Pods/Pods.xcodeproj/project.pbxproj +++ b/Bluejay/Pods/Pods.xcodeproj/project.pbxproj @@ -26,33 +26,33 @@ 1BF71D1EC28BF858D281FA1F18EA8DF6 /* Pods-BluejayDemo.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-BluejayDemo.release.xcconfig"; sourceTree = ""; }; 1DDBE844480717A12679DA5AF01CE404 /* Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 27926CF5568D76460F12849898C54FC7 /* Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; - 2A73B86643BFED12592A8D31C6DCF847 /* Pods_Bluejay.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; name = Pods_Bluejay.framework; path = "Pods-Bluejay.framework"; sourceTree = BUILT_PRODUCTS_DIR; }; + 2A73B86643BFED12592A8D31C6DCF847 /* Pods_Bluejay.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Bluejay.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 4007F0819AA9B8D1DC91D6AD25B63B11 /* Pods-BluejayDemo-umbrella.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "Pods-BluejayDemo-umbrella.h"; sourceTree = ""; }; 5C74BA9CB6B49B8B954C09743C2E2542 /* Pods-Bluejay.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-Bluejay.release.xcconfig"; sourceTree = ""; }; 5E57F28B529666BC0B5ED638FF3B2D6D /* Pods-BluejayTests-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = "Pods-BluejayTests-dummy.m"; sourceTree = ""; }; 5EF8F2F84A39EC89F6447081484FE5E0 /* Pods-Bluejay.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-Bluejay.debug.xcconfig"; sourceTree = ""; }; 691F45B8279510D3CCCE3BF3BAEE0A70 /* Pods-BluejayTests-acknowledgements.markdown */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text; path = "Pods-BluejayTests-acknowledgements.markdown"; sourceTree = ""; }; - 6DE738BDB6DEF353136B65245834BD75 /* Pods_BluejayDemo.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; name = Pods_BluejayDemo.framework; path = "Pods-BluejayDemo.framework"; sourceTree = BUILT_PRODUCTS_DIR; }; + 6DE738BDB6DEF353136B65245834BD75 /* Pods_BluejayDemo.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_BluejayDemo.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 6F2A71DD6A680CD4CAA83B1DE66DE839 /* Pods-BluejayTests-umbrella.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "Pods-BluejayTests-umbrella.h"; sourceTree = ""; }; 7A15FEEC244C47ED07CB011B6A2A6FFD /* Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 7EA571AE206A67F78393CE2DA76A1D0D /* Pods-BluejayDemo-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = "Pods-BluejayDemo-dummy.m"; sourceTree = ""; }; 81A9654EE67EA6FA4936FE864E21C5F1 /* Pods-BluejayTests-resources.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-BluejayTests-resources.sh"; sourceTree = ""; }; - 889B1643E32EFAE76E3858139BE0A32E /* Pods-Bluejay.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; path = "Pods-Bluejay.modulemap"; sourceTree = ""; }; + 889B1643E32EFAE76E3858139BE0A32E /* Pods-Bluejay.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = "sourcecode.module-map"; path = "Pods-Bluejay.modulemap"; sourceTree = ""; }; 8F884B509C2CF4D49CC594F9298E1CB5 /* Pods-BluejayTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-BluejayTests.release.xcconfig"; sourceTree = ""; }; 91877DB5C1A91D76820F80CC853CC037 /* Pods-BluejayTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-BluejayTests.debug.xcconfig"; sourceTree = ""; }; - 93A4A3777CF96A4AAC1D13BA6DCCEA73 /* Podfile */ = {isa = PBXFileReference; explicitFileType = text.script.ruby; includeInIndex = 1; lastKnownFileType = text; name = Podfile; path = ../Podfile; sourceTree = SOURCE_ROOT; xcLanguageSpecificationIdentifier = xcode.lang.ruby; }; + 93A4A3777CF96A4AAC1D13BA6DCCEA73 /* Podfile */ = {isa = PBXFileReference; explicitFileType = text.script.ruby; includeInIndex = 1; name = Podfile; path = ../Podfile; sourceTree = SOURCE_ROOT; xcLanguageSpecificationIdentifier = xcode.lang.ruby; }; 9D4EC62A72D604DD7CBB2ABDC9596C91 /* Pods-Bluejay-umbrella.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "Pods-Bluejay-umbrella.h"; sourceTree = ""; }; A53E5800DBE7BAEE434B1E6F12ED35C5 /* Pods-BluejayTests-frameworks.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-BluejayTests-frameworks.sh"; sourceTree = ""; }; - A5BCFDC62E94590E2E4C39641AF5E6E7 /* Pods-BluejayDemo.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; path = "Pods-BluejayDemo.modulemap"; sourceTree = ""; }; + A5BCFDC62E94590E2E4C39641AF5E6E7 /* Pods-BluejayDemo.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = "sourcecode.module-map"; path = "Pods-BluejayDemo.modulemap"; sourceTree = ""; }; AAC81449B34EAD25788A7741FF0C3720 /* Pods-BluejayDemo-frameworks.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-BluejayDemo-frameworks.sh"; sourceTree = ""; }; AEE1B02235340346E5ECC801CAF1E8E0 /* Pods-Bluejay-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = "Pods-Bluejay-dummy.m"; sourceTree = ""; }; BB80C8D6F8146F43DA4F6F54538692C2 /* Pods-Bluejay-resources.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-Bluejay-resources.sh"; sourceTree = ""; }; - BC65483ECC97B166754F39CF2DC06997 /* Pods-BluejayTests.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; path = "Pods-BluejayTests.modulemap"; sourceTree = ""; }; + BC65483ECC97B166754F39CF2DC06997 /* Pods-BluejayTests.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = "sourcecode.module-map"; path = "Pods-BluejayTests.modulemap"; sourceTree = ""; }; C3B4E09E9D14F32E9308B0CD849EAD86 /* Pods-BluejayDemo.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-BluejayDemo.debug.xcconfig"; sourceTree = ""; }; CBB3DE36805AF21409EC968A9691732F /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS10.0.sdk/System/Library/Frameworks/Foundation.framework; sourceTree = DEVELOPER_DIR; }; D4E98FADA2216B6DC43A01FF2399D59F /* Pods-BluejayDemo-acknowledgements.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = "Pods-BluejayDemo-acknowledgements.plist"; sourceTree = ""; }; F77B67DE051E68E5849BBD9D9AE4610F /* Pods-BluejayDemo-resources.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-BluejayDemo-resources.sh"; sourceTree = ""; }; - FCFD7E7B2704AF25F8D26879BB4CBF83 /* Pods_BluejayTests.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; name = Pods_BluejayTests.framework; path = "Pods-BluejayTests.framework"; sourceTree = BUILT_PRODUCTS_DIR; }; + FCFD7E7B2704AF25F8D26879BB4CBF83 /* Pods_BluejayTests.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_BluejayTests.framework; sourceTree = BUILT_PRODUCTS_DIR; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -270,7 +270,7 @@ isa = PBXProject; attributes = { LastSwiftUpdateCheck = 0730; - LastUpgradeCheck = 0700; + LastUpgradeCheck = 0930; }; buildConfigurationList = 2D8E8EC45A3A1A1D94AE762CB5028504 /* Build configuration list for PBXProject "Pods" */; compatibilityVersion = "Xcode 3.2"; @@ -363,20 +363,32 @@ CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES; CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; CODE_SIGNING_REQUIRED = NO; COPY_PHASE_STRIP = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; ENABLE_TESTABILITY = YES; GCC_C_LANGUAGE_STANDARD = gnu99; GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; GCC_OPTIMIZATION_LEVEL = 0; GCC_PREPROCESSOR_DEFINITIONS = ( "POD_CONFIGURATION_DEBUG=1", @@ -512,19 +524,31 @@ CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES; CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; CODE_SIGNING_REQUIRED = NO; COPY_PHASE_STRIP = YES; ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; GCC_PREPROCESSOR_DEFINITIONS = ( "POD_CONFIGURATION_RELEASE=1", "$(inherited)",