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

[SR-7299] ReactiveCocoa source breakage: error: ambiguous use of 'numberOfArguments' #49847

Closed
clackary opened this issue Mar 28, 2018 · 11 comments

Comments

@clackary
Copy link
Contributor

clackary commented Mar 28, 2018

Previous ID SR-7299
Radar rdar://problem/38975913
Original Reporter @clackary
Type Bug
Status Closed
Resolution Done
Additional Detail from JIRA
Votes 0
Component/s Compiler
Labels Bug, SourceCompatibility
Assignee @hamishknight
Priority Medium

md5: 1a24eaf6ed6e4769e51ca9a6fa9a6fcf

Issue Description:

To reproduce:

  1. Install latest GM/Beta Xcode
  2. $ git clone git@github.com:apple/swift-source-compat-suite.git
  3. $ cd swift-source-compat-suite

To build Swift from scratch before testing:
4. $ ./reproduce.py master --project-path ReactiveCocoa

Or if you've already built Swift:
4. $ ./reproduce.py master --project-path ReactiveCocoa --swiftc path/to/swiftc

https://ci.swift.org/job/swift-master-source-compat-suite/1527/artifact/swift-source-compat-suite/

/Users/buildnode/jenkins/workspace-private/swift-master-source-compat-suite/project_cache/ReactiveCocoa/ReactiveCocoa/NSObject+Intercepting.swift:387:19: error: ambiguous use of 'numberOfArguments'
        let count = UInt(methodSignature.numberOfArguments!)
                         ^
@clackary
Copy link
Contributor Author

clackary commented Mar 28, 2018

FAIL_ReactiveCocoa_3.0_BuildXcodeWorkspaceScheme_ReactiveCocoa-iOS_generic-platform-iOS.log FAIL_ReactiveCocoa_3.0_BuildXcodeWorkspaceScheme_ReactiveCocoa-tvOS_generic-platform-tvOS.log FAIL_ReactiveCocoa_3.2_BuildXcodeWorkspaceScheme_ReactiveCocoa-iOS_generic-platform-iOS.log FAIL_ReactiveCocoa_3.2_BuildXcodeWorkspaceScheme_ReactiveCocoa-tvOS_generic-platform-tvOS.log FAIL_ReactiveCocoa_4.0_BuildXcodeWorkspaceScheme_ReactiveCocoa-iOS_generic-platform-iOS.log FAIL_ReactiveCocoa_4.0_BuildXcodeWorkspaceScheme_ReactiveCocoa-tvOS_generic-platform-tvOS.log

@clackary
Copy link
Contributor Author

clackary commented Mar 28, 2018

I have a PR to add xfails for these failing configurations.

apple/swift-source-compat-suite#172

@aschwaighofer
Copy link
Member

aschwaighofer commented Mar 28, 2018

This was exposed by #15412

@aschwaighofer
Copy link
Member

aschwaighofer commented Mar 28, 2018

cc @belkadan @DougGregor who are on the thread of the PR

@clackary
Copy link
Contributor Author

clackary commented Mar 28, 2018

@swift-ci create

@belkadan
Copy link
Contributor

belkadan commented Mar 29, 2018

Doug and I are leaning towards asking the ReactiveCocoa folks for an update, since previously they were basically getting an arbitrarily-chosen numberOfArguments overload. Since the types of the two possibilities were Int and UInt this wasn't too harmful, but it could have been much worse (imagine Int and CGFloat for some other property).

@clackary, what do you think?

@clackary
Copy link
Contributor Author

clackary commented Mar 29, 2018

@belkadan, I'd echo the concerns that aschwaighofer@apple.com (JIRA User) mentioned on https://github.com/apple/swift/pull/15412. There's a risk in keeping xfails on a sizable chunk of ReactiveCocoa configurations. It could create a window for introducing bugs.

That being said, if this ambiguity error isn't the result of a new compiler bug, reaching out to the ReactiveCocoa maintainer for an update is probably the right thing to do.

@hamishknight
Copy link
Collaborator

hamishknight commented Mar 30, 2018

PR for ReactiveCocoa's fix: ReactiveCocoa/ReactiveCocoa#3580

@swift-ci
Copy link
Collaborator

swift-ci commented Mar 30, 2018

Comment by Anders Ha (JIRA)

Compatibility Suite Update: apple/swift-source-compat-suite#174

@hamishknight
Copy link
Collaborator

hamishknight commented Mar 30, 2018

Resolved by the above linked pull requests.

@clackary
Copy link
Contributor Author

clackary commented Apr 4, 2018

Closing this out, but this did uncover another issue, tracked here: https://bugs.swift.org/browse/SR-7346

@swift-ci swift-ci transferred this issue from apple/swift-issues Apr 25, 2022
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants