Skip to content

Casting from AnyHashable to AnyHashable should never create another wrapper #36470

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 2 commits into from
Mar 22, 2021

Conversation

tbkka
Copy link
Contributor

@tbkka tbkka commented Mar 17, 2021

This adds a conformance for _HasCustomAnyHashableRepresentation to
AnyHashable that simply returns self. This ensures that anytime
you try to create a new AnyHashable wrapper for an existing
AnyHashable, you just get back the original.

Resolves rdar://75180619

…rapper

This adds a conformance for _HasCustomAnyHashableRepresentation to
AnyHashable that simply returns self.  This ensures that anytime
you try to create a new AnyHashable wrapper for an existing
AnyHashable, you just get back the original.

Resolves rdar://75180619
@tbkka tbkka requested a review from lorentey March 17, 2021 19:41
@tbkka
Copy link
Contributor Author

tbkka commented Mar 18, 2021

@swift-ci Please test

@swift-ci
Copy link
Contributor

Build failed
Swift Test Linux Platform
Git Sha - 773c679

@tbkka
Copy link
Contributor Author

tbkka commented Mar 18, 2021

@swift-ci Please test Linux platform

Copy link
Member

@lorentey lorentey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! 👍 See comments on some test issues.

@tbkka
Copy link
Contributor Author

tbkka commented Mar 19, 2021

@swift-ci Please test

@swift-ci
Copy link
Contributor

Build failed
Swift Test OS X Platform
Git Sha - 855b1fb

@tbkka
Copy link
Contributor Author

tbkka commented Mar 19, 2021

@swift-ci Please test macOS Platform

@tbkka
Copy link
Contributor Author

tbkka commented Mar 19, 2021

@swift-ci Please test Windows Platform

@tbkka tbkka merged commit 26ab276 into swiftlang:main Mar 22, 2021
@tbkka tbkka deleted the tbkka/anyHashableCasts branch March 22, 2021 16:03
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