Avatar
Avatar
nanasi
@swift-5.7.3 @swift-main private extension Equatable { func isEquals(_ other: any Equatable) -> Bool { guard let other = other as? Self else { return false } return self == other } } public func == (lhs: any Equatable, rhs: any Equatable) -> Bool { lhs.isEquals(rhs) } let i: any Equatable = 1 let d: any Equatable = 1.0 let i2: any Equatable = 1 print(i == d) print(i == i2)
exit status: 139 with stderr:Stack dump: 0. Program arguments: /usr/bin/swift-frontend -frontend -interpret - -disable-objc-interop -new-driver-path /usr/bin/swift-driver -empty-abi-descriptor -resource-dir /usr/lib/swift -module-name main 1. Swift version 5.7.1 (swift-5.7.1-RELEASE) 2. Compiling with the current language version 3. While running user code "<stdin>" Stack dump without symbol names (ensure you have llvm-symbolizer in your PATH or set the environment var `LLVM_SYMBOLIZER_PATH` to point to it): /usr/bin/swift-frontend(+0x551a083)[0x5643df6e6083] /usr/bin/swift-frontend(+0x5517fae)[0x5643df6e3fae] /usr/bin/swift-frontend(+0x551a40a)[0x5643df6e640a] /lib/x86_64-linux-gnu/libc.so.6(+0x42520)[0x7ffa50f4d520] /usr/lib/swift/linux/libswiftCore.so(+0x42192f)[0x7ffa518e192f] /usr/lib/swift/linux/libswiftCore.so(+0x3fad00)[0x7ffa518bad00]