Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Promise+Recover.swift does not compile for macOS / Swift 4 #54

Closed
stefanhp opened this issue Oct 2, 2017 · 6 comments
Closed

Promise+Recover.swift does not compile for macOS / Swift 4 #54

stefanhp opened this issue Oct 2, 2017 · 6 comments
Labels
Milestone

Comments

@stefanhp
Copy link

stefanhp commented Oct 2, 2017

I get the following compile error:

/Users/stefan/Documents/Git-Workspace/Modules/Hydra/Sources/Hydra/Promise+Recover.swift:47:11: error: ambiguous reference to member 'then(in:_:)'
                        return self.then(in: ctx, {
                               ^~~~
/Users/stefan/Documents/Git-Workspace/Modules/Hydra/Sources/Hydra/Promise+Then.swift:48:14: note: found this candidate
        public func then<N>(in context: Context? = nil, _ body: @escaping ( (Value) throws -> N) ) -> Promise<N> {
                    ^
/Users/stefan/Documents/Git-Workspace/Modules/Hydra/Sources/Hydra/Promise+Then.swift:76:14: note: found this candidate
        public func then<N>(in context: Context? = nil, _ body: @escaping ( (Value) throws -> (Promise<N>) )) -> Promise<N> {
                    ^
/Users/stefan/Documents/Git-Workspace/Modules/Hydra/Sources/Hydra/Promise+Then.swift:118:14: note: found this candidate
        public func then(in context: Context? = nil, _ body: @escaping ( (Value) throws -> () ) ) -> Promise<Value> {
                    ^

I'm using Xcode 9.0 (9A235), swift 4 and a deployment target of 10.12.

@stefanhp
Copy link
Author

stefanhp commented Oct 2, 2017

The same code compiles for iOS 10 though.

@malcommac
Copy link
Owner

Are you using Hydra 1.1.0 (or later)?

@stefanhp
Copy link
Author

stefanhp commented Oct 3, 2017

I'm using 1.1.0, the latest head commit 95725e9

@stefanhp
Copy link
Author

stefanhp commented Oct 3, 2017

I'm using Hydra as a submodule, but the same happens when you compile the Hydra-macOS target in your Hydra.xcodeproj project, using Xcode 9.0.

@leepfrog
Copy link

leepfrog commented Oct 3, 2017

I think #51 & #52 are the same issue as well

malcommac added a commit that referenced this issue Oct 27, 2017
@malcommac
Copy link
Owner

Promise+Recover was missing from Xcode target sic!
Solved

@malcommac malcommac added this to the 1.2.0 milestone Oct 27, 2017
@malcommac malcommac added the bug label Oct 27, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants