diff --git a/.travis.yml b/.travis.yml index 1f423f1..f73fdb7 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,5 +1,5 @@ language: objective-c -osx_image: xcode8.2 +osx_image: xcode9.2 git: submodules: false before_install: @@ -11,7 +11,7 @@ script: - set -o pipefail - xcodebuild test -scheme Tyro -configuration Debug | xcpretty -c - xcodebuild test -scheme Tyro-iOS -configuration Debug -sdk iphonesimulator -destination "platform=iOS Simulator,name=iPhone 6s" | xcpretty -c - - xcodebuild test -scheme Tyro-tvOS -destination 'platform=tvOS Simulator,name=Apple TV 1080p' | xcpretty -c + - xcodebuild test -scheme Tyro-tvOS -destination 'platform=tvOS Simulator,name=Apple TV' | xcpretty -c - xcodebuild build -scheme Tyro-watchOS -destination 'platform=watchOS Simulator,name=Apple Watch - 42mm' | xcpretty -c # deploy: # provider: script diff --git a/Cartfile.private b/Cartfile.private index 26ae81f..5157273 100644 --- a/Cartfile.private +++ b/Cartfile.private @@ -1 +1 @@ -github "typelift/SwiftCheck" ~> 0.6.2 +github "typelift/SwiftCheck" ~> 0.8.1 diff --git a/Carthage/Checkouts/SwiftCheck b/Carthage/Checkouts/SwiftCheck index 0e2d31c..2e13644 160000 --- a/Carthage/Checkouts/SwiftCheck +++ b/Carthage/Checkouts/SwiftCheck @@ -1 +1 @@ -Subproject commit 0e2d31cbf718cc31bb2f80a65760439ecc3ee7fc +Subproject commit 2e136441c8096bb1e5d3c2b12bdd63f8a45a674b diff --git a/Carthage/Checkouts/Swiftz b/Carthage/Checkouts/Swiftz index 82bf915..c0c2278 160000 --- a/Carthage/Checkouts/Swiftz +++ b/Carthage/Checkouts/Swiftz @@ -1 +1 @@ -Subproject commit 82bf915555ef1dbffe658c01ae3997d4f40db6ef +Subproject commit c0c22789ede4aa036c52aa5c8ec5fc5378877fd1 diff --git a/Tyro.xcodeproj/project.pbxproj b/Tyro.xcodeproj/project.pbxproj index 00487e4..5524d28 100644 --- a/Tyro.xcodeproj/project.pbxproj +++ b/Tyro.xcodeproj/project.pbxproj @@ -766,7 +766,7 @@ isa = PBXProject; attributes = { LastSwiftUpdateCheck = 0730; - LastUpgradeCheck = 0800; + LastUpgradeCheck = 0900; ORGANIZATIONNAME = TypeLift; TargetAttributes = { 823739711CC99B1400CBAF3C = { @@ -1354,14 +1354,20 @@ 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_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 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_LITERAL_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + 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; @@ -1406,14 +1412,20 @@ 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_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 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_LITERAL_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + 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; @@ -1434,6 +1446,7 @@ IPHONEOS_DEPLOYMENT_TARGET = 8.0; MTL_ENABLE_DEBUG_INFO = NO; SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; SWIFT_VERSION = 3.0; TARGETED_DEVICE_FAMILY = "1,2"; VALIDATE_PRODUCT = YES; diff --git a/Tyro.xcodeproj/xcshareddata/xcschemes/Tyro-iOS.xcscheme b/Tyro.xcodeproj/xcshareddata/xcschemes/Tyro-iOS.xcscheme index 284f7ed..f4ce1d5 100644 --- a/Tyro.xcodeproj/xcshareddata/xcschemes/Tyro-iOS.xcscheme +++ b/Tyro.xcodeproj/xcshareddata/xcschemes/Tyro-iOS.xcscheme @@ -1,6 +1,6 @@ @@ -56,6 +57,7 @@ buildConfiguration = "Debug" selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" + language = "" launchStyle = "0" useCustomWorkingDirectory = "NO" ignoresPersistentStateOnLaunch = "NO" diff --git a/Tyro.xcodeproj/xcshareddata/xcschemes/Tyro-tvOS.xcscheme b/Tyro.xcodeproj/xcshareddata/xcschemes/Tyro-tvOS.xcscheme index f69b7dc..1cbd17c 100644 --- a/Tyro.xcodeproj/xcshareddata/xcschemes/Tyro-tvOS.xcscheme +++ b/Tyro.xcodeproj/xcshareddata/xcschemes/Tyro-tvOS.xcscheme @@ -1,6 +1,6 @@ @@ -36,6 +37,7 @@ buildConfiguration = "Debug" selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" + language = "" launchStyle = "0" useCustomWorkingDirectory = "NO" ignoresPersistentStateOnLaunch = "NO" diff --git a/Tyro.xcodeproj/xcshareddata/xcschemes/Tyro.xcscheme b/Tyro.xcodeproj/xcshareddata/xcschemes/Tyro.xcscheme index 4ef90a4..d9a32d4 100644 --- a/Tyro.xcodeproj/xcshareddata/xcschemes/Tyro.xcscheme +++ b/Tyro.xcodeproj/xcshareddata/xcschemes/Tyro.xcscheme @@ -1,6 +1,6 @@ @@ -56,6 +57,7 @@ buildConfiguration = "Debug" selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" + language = "" launchStyle = "0" useCustomWorkingDirectory = "NO" ignoresPersistentStateOnLaunch = "NO" diff --git a/Tyro/Formatter.swift b/Tyro/Formatter.swift index 6dff421..267cfa4 100644 --- a/Tyro/Formatter.swift +++ b/Tyro/Formatter.swift @@ -13,7 +13,7 @@ public protocol JSONValueConvertible : JSONDecoderType { var jsonValue : JSONValue? { get } } -public protocol JSONFormatterType : JSONDecoderType, JSONEncoderType, JSONValueConvertible { +public protocol JSONFormatterType : JSONEncoderType, JSONValueConvertible { associatedtype T associatedtype EncodedType = T associatedtype DecodedType = T diff --git a/Tyro/Info.plist b/Tyro/Info.plist index abe61f5..6019f05 100644 --- a/Tyro/Info.plist +++ b/Tyro/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 0.1.0 + 0.2.0 CFBundleSignature ???? CFBundleVersion diff --git a/Tyro/JSONOperators.swift b/Tyro/JSONOperators.swift index 802f9cb..fa4544d 100644 --- a/Tyro/JSONOperators.swift +++ b/Tyro/JSONOperators.swift @@ -72,7 +72,7 @@ public func (lhs : JSONValue?, rhs : JSONKeypath) throws -> A w return result } else { - throw JSONError.Custom("Could not find value at keypath \(rhs) in JSONValue : \(lhs)") + throw JSONError.Custom("Could not find value at keypath \(rhs) in JSONValue : \(String(describing: lhs))") } } @@ -81,7 +81,7 @@ public func (lhs : JSONValue?, rhs : JSONKeypath) throws -> [A] return result } else { - throw JSONError.Custom("Could not find value at keypath \(rhs) in JSONValue : \(lhs)") + throw JSONError.Custom("Could not find value at keypath \(rhs) in JSONValue : \(String(describing: lhs))") } } @@ -90,6 +90,6 @@ public func (lhs : JSONValue?, rhs : JSONKeypath) throws -> [St return result } else { - throw JSONError.Custom("Could not find value at keypath \(rhs) in JSONValue : \(lhs)") + throw JSONError.Custom("Could not find value at keypath \(rhs) in JSONValue : \(String(describing: lhs))") } }