-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
CustomPersistable
is not working properly with Xcode 16 Release Candidate
#8686
Comments
github-actions
bot
added
Encryption:Off
Frequency:Always
Repro:Always
SDK-Use:Local
labels
Sep 14, 2024
➤ PM Bot commented: Jira ticket: RCOCOA-2433 |
I seems like relative to the @OriTheElf we may needed to do something like: @available(iOS, obsoleted: 18)
extension CGPoint: @retroactive Hashable {
public var hashValue: Int {
var hasher = Hasher()
hash(into: &hasher)
return hasher.finalize()
}
public func hash(into hasher: inout Hasher) {
hasher.combine(x)
hasher.combine(y)
}
} |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
How frequently does the bug occur?
Always
Description
With CGPoint confirming protocol
CustomPersistable
, crashed with Xcode 16 Release Candidate, Swift 6, but not exist with Xcode 15.4, Swift 5.Demo: https://github.com/ziiip/realm-swift-iOS-demo/tree/xcode16_swift6_ios17_or_below
Please checkout the branch, pod again, and run on device with iOS 17.6.1 or below.
We can see warning in Xcode 16: Conformance of 'CGPoint' to 'Hashable' is only available in iOS 18.0 or newer; this is an error in the Swift 6 language mode
Key code:
Stacktrace & log output
Can you reproduce the bug?
Always
Reproduction Steps
Demo: https://github.com/ziiip/realm-swift-iOS-demo/tree/xcode16_swift6_ios17_or_below
Please checkout the branch, pod again, and run on device with iOS 17.6.1 or below.
Version
10.53.1
What Atlas Services are you using?
Local Database only
Are you using encryption?
No
Platform OS and version(s)
iOS 17.5.1
Build environment
Xcode 16
Using Realm with CocoaPods
The text was updated successfully, but these errors were encountered: