From 7d2d164d671c31f620a8db46298c65eec4d1b157 Mon Sep 17 00:00:00 2001 From: Antihevich Date: Thu, 21 Sep 2017 14:51:26 +0300 Subject: [PATCH] Swift 3.2 migration. --- .swift-version | 2 +- .travis.yml | 2 +- AppRouter.podspec | 2 +- AppRouter.xcodeproj/project.pbxproj | 18 +++++++++++++++++- CHANGELOG.md | 5 +++++ Cartfile | 2 +- Cartfile.resolved | 2 +- Carthage/Checkouts/RxSwift | 2 +- Plists/AppRouter.plist | 2 +- README.md | 4 ++-- Sources/Core/AppRouter+presenter.swift | 2 +- 11 files changed, 32 insertions(+), 11 deletions(-) diff --git a/.swift-version b/.swift-version index 8c50098..a3ec5a4 100644 --- a/.swift-version +++ b/.swift-version @@ -1 +1 @@ -3.1 +3.2 diff --git a/.travis.yml b/.travis.yml index 8c19b3d..b946432 100755 --- a/.travis.yml +++ b/.travis.yml @@ -4,7 +4,7 @@ matrix: env: ACTION=iOS language: objective-c -osx_image: xcode8.3 +osx_image: xcode9 script: - git submodule update --init --recursive diff --git a/AppRouter.podspec b/AppRouter.podspec index 81f66ed..bae9699 100755 --- a/AppRouter.podspec +++ b/AppRouter.podspec @@ -1,7 +1,7 @@ Pod::Spec.new do |s| s.name = "AppRouter" - s.version = "4.0.1" + s.version = "4.0.2" s.summary = "UIViewController creation, navigation, utility methods for easy routing" s.homepage = "https://github.com/MLSDev/AppRouter" diff --git a/AppRouter.xcodeproj/project.pbxproj b/AppRouter.xcodeproj/project.pbxproj index fe904b6..4492be8 100755 --- a/AppRouter.xcodeproj/project.pbxproj +++ b/AppRouter.xcodeproj/project.pbxproj @@ -50,6 +50,13 @@ /* End PBXBuildFile section */ /* Begin PBXContainerItemProxy section */ + C045B9ED1F73DB0C0012170E /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = C0A127C31D59C0440057F9E8 /* Rx.xcodeproj */; + proxyType = 2; + remoteGlobalIDString = C8E8BA551E2C181A00A4AC2C; + remoteInfo = Benchmarks; + }; C089D3291D54A3BF00599DD7 /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = 9AC8C9E71969BBB5006F1EAC /* Project object */; @@ -417,6 +424,7 @@ C0A127FD1D59C0440057F9E8 /* AllTests-tvOS.xctest */, C0A127FF1D59C0440057F9E8 /* AllTests-macOS.xctest */, C0A128011D59C0440057F9E8 /* PerformanceTests.app */, + C045B9EE1F73DB0C0012170E /* Benchmarks.xctest */, ); name = Products; sourceTree = ""; @@ -618,6 +626,13 @@ /* End PBXProject section */ /* Begin PBXReferenceProxy section */ + C045B9EE1F73DB0C0012170E /* Benchmarks.xctest */ = { + isa = PBXReferenceProxy; + fileType = wrapper.cfbundle; + path = Benchmarks.xctest; + remoteRef = C045B9ED1F73DB0C0012170E /* PBXContainerItemProxy */; + sourceTree = BUILT_PRODUCTS_DIR; + }; C0A127DB1D59C0440057F9E8 /* RxSwift.framework */ = { isa = PBXReferenceProxy; fileType = wrapper.framework; @@ -754,7 +769,8 @@ C0A128011D59C0440057F9E8 /* PerformanceTests.app */ = { isa = PBXReferenceProxy; fileType = wrapper.application; - path = PerformanceTests.app; + name = PerformanceTests.app; + path = Microoptimizations.app; remoteRef = C0A128001D59C0440057F9E8 /* PBXContainerItemProxy */; sourceTree = BUILT_PRODUCTS_DIR; }; diff --git a/CHANGELOG.md b/CHANGELOG.md index efa0446..0b950f2 100755 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,11 @@ All notable changes to this project will be documented in this file. +## [4.0.2](https://github.com/MLSDev/AppRouter/releases/tag/4.0.2) + +Swift 3.2 migration. + + ## [4.0.1](https://github.com/MLSDev/AppRouter/releases/tag/4.0.1) Presenter namespace-enum changed into open class to prevent weird bug with overrides. diff --git a/Cartfile b/Cartfile index d32ce81..e8ff1f9 100644 --- a/Cartfile +++ b/Cartfile @@ -1 +1 @@ -github "ReactiveX/RxSwift" +github "ReactiveX/RxSwift" "rxswift4.0-swift4.0" diff --git a/Cartfile.resolved b/Cartfile.resolved index 1e2ad8d..929db1f 100644 --- a/Cartfile.resolved +++ b/Cartfile.resolved @@ -1 +1 @@ -github "ReactiveX/RxSwift" "3.0.0" +github "ReactiveX/RxSwift" "a0bf386834ca09e0438e2edf03d740eac3c4a6ce" diff --git a/Carthage/Checkouts/RxSwift b/Carthage/Checkouts/RxSwift index 3c55a30..a0bf386 160000 --- a/Carthage/Checkouts/RxSwift +++ b/Carthage/Checkouts/RxSwift @@ -1 +1 @@ -Subproject commit 3c55a309a24fbe3dbc480431798eec072b633b85 +Subproject commit a0bf386834ca09e0438e2edf03d740eac3c4a6ce diff --git a/Plists/AppRouter.plist b/Plists/AppRouter.plist index d7feac3..aa59408 100755 --- a/Plists/AppRouter.plist +++ b/Plists/AppRouter.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 4.0.1 + 4.0.2 CFBundleSignature ???? CFBundleVersion diff --git a/README.md b/README.md index c07bd2f..5bd9280 100644 --- a/README.md +++ b/README.md @@ -11,8 +11,8 @@ Extremely easy way to handle controller creation / presentation / navigation and ## Requirements - iOS 8.0+ -- Xcode 8+ -- Swift 3 +- Xcode 9+ +- Swift 3.2 ## Installation diff --git a/Sources/Core/AppRouter+presenter.swift b/Sources/Core/AppRouter+presenter.swift index 1a3941c..8a716ad 100644 --- a/Sources/Core/AppRouter+presenter.swift +++ b/Sources/Core/AppRouter+presenter.swift @@ -309,7 +309,7 @@ extension AppRouter.Presenter { case customXib(String) case preconstructed(UIViewController) case anonymous(() throws -> UIViewController) - public func provideController() throws -> T where T : BundleForClassInstantiable { + public func provideController() throws -> T { switch self { case .storyboard(let initial): return try T.instantiate(initial: initial) ?? Errors.failedToConstructSourceController.rethrow()