Skip to content

Revert "[Diagnostics] Hint contextual type diagnostics with expression type if known" #16575

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

Merged
merged 1 commit into from
May 12, 2018

Conversation

huonw
Copy link
Contributor

@huonw huonw commented May 12, 2018

Reverts #16556

I strongly suspect this is causing failures like https://ci.swift.org/job/oss-swift-package-osx/1664/:

07:18:14 FAIL: Swift(macosx-x86_64) :: Constraints/diagnostics.swift (10920 of 11116)
07:18:14 
******************** TEST 'Swift(macosx-x86_64) :: Constraints/diagnostics.swift' FAILED ********************
07:18:14 Script:
07:18:14 --
07:18:14 /Users/buildnode/jenkins/workspace/oss-swift-package-osx/build/buildbot_osx/swift-macosx-x86_64/bin/swiftc -frontend -target x86_64-apple-macosx10.9  -module-cache-path '/Users/buildnode/jenkins/workspace/oss-swift-package-osx/build/buildbot_osx/swift-macosx-x86_64/swift-test-results/x86_64-apple-macosx10.9/clang-module-cache' -sdk /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk -swift-version 3  -typecheck -verify -disable-objc-attr-requires-foundation-module /Users/buildnode/jenkins/workspace/oss-swift-package-osx/swift/test/Constraints/diagnostics.swift
07:18:14 --
07:18:14 Exit Code: 1
07:18:14 
07:18:14 Command Output (stderr):
07:18:14 --
07:18:14 
/Users/buildnode/jenkins/workspace/oss-swift-package-osx/swift/test/Constraints/diagnostics.swift:536:77: error: incorrect message found
07:18:14   let closureIndex = closures.index{$0 === testClosure} // expected-error {{cannot check reference equality of functions; operands here have types '_' and '([Int]) -> Bool'}}
07:18:14                                                                             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
07:18:14                                                                             cannot check reference equality of functions; operands here have types 'MyClosure' (aka '(Array<Int>) -> Bool') and '([Int]) -> Bool'
07:18:14 
07:18:14 --

@huonw
Copy link
Contributor Author

huonw commented May 12, 2018

@swift-ci please test and merge

@huonw
Copy link
Contributor Author

huonw commented May 12, 2018

cc @xedin

@swift-ci swift-ci merged commit 65119c8 into master May 12, 2018
@xedin
Copy link
Contributor

xedin commented May 12, 2018

It looks like that test-case must have been added after I ran all of the tests, because my full suite was green...

@xedin
Copy link
Contributor

xedin commented May 12, 2018

Re-applying via #16576

@huonw
Copy link
Contributor Author

huonw commented May 12, 2018

It looks like that test-case must have been added after I ran all of the tests, because my full suite was green...

No, it was added in 2015/2016. It seems to only be failing occasionally, so it's possible that it either just happened to pass on all the pull request CI platforms when your patch landed, or that it wasn't caused by your patch.

@huonw huonw deleted the revert-16556-rdar-40002266 branch May 12, 2018 22:53
@huonw
Copy link
Contributor Author

huonw commented May 12, 2018

I just looked through the CI bots, and the ones that failed are now passing (across multiple builds) that this has landed, so I'm even more inclined to say it was your patch. :( it's always annoying when it's not consistent.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants