We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
md5: b9248ab3bcd67bb0e197283e26f1749d
relates to:
Issue Description:
I have seen this a few times. A workaround is below (commented out) but I'm not sure this is the correct approach.
The text was updated successfully, but these errors were encountered:
@phausler suggested using bitPattern and this appears to fix the problem, which has also appeared in the following places (fixes below).
[rand:~/CVSRoot/apple/swift-corelibs-foundation] lukeh% git diff diff --git a/Foundation/NSSwiftRuntime.swift b/Foundation/NSSwiftRuntime.swift index ef1f848..d35af03 100644 --- a/Foundation/NSSwiftRuntime.swift +++ b/Foundation/NSSwiftRuntime.swift @@ -83,7 +83,7 @@ internal func _CFSwiftGetTypeID(cf: AnyObject) -> CFTypeID { internal func _CFSwiftGetHash(cf: AnyObject) -> CFHashCode { - return CFHashCode((cf as! NSObject).hash) + return CFHashCode(bitPattern: (cf as! NSObject).hash) } diff --git a/Foundation/NSURL.swift b/Foundation/NSURL.swift index 73f0bdb..9c103b0 100644 --- a/Foundation/NSURL.swift +++ b/Foundation/NSURL.swift @@ -60,7 +60,7 @@ public class NSURL : NSObject, NSSecureCoding, NSCopying { public override var hash: Int { get { - return Int(CFHash(_cfObject)) + return Int(bitPattern: CFHash(_cfObject)) } }
Sorry, something went wrong.
integrated in c120398
phausler
No branches or pull requests
Additional Detail from JIRA
md5: b9248ab3bcd67bb0e197283e26f1749d
relates to:
Issue Description:
I have seen this a few times. A workaround is below (commented out) but I'm not sure this is the correct approach.
The text was updated successfully, but these errors were encountered: