File tree 1 file changed +6
-11
lines changed
1 file changed +6
-11
lines changed Original file line number Diff line number Diff line change @@ -187,17 +187,12 @@ internal final class __SwiftValue : NSObject, NSCopying {
187
187
} else if let opt = value as? Unwrappable , opt. unwrap ( ) == nil {
188
188
return NSNull ( )
189
189
} else {
190
- #if canImport(ObjectiveC)
191
- // On Darwin, this can be a native (ObjC) __SwiftValue.
192
- let boxed = ( value as AnyObject )
193
- if !( boxed is NSObject ) {
194
- return __SwiftValue ( value) // Do not emit native boxes — wrap them in Swift Foundation boxes instead.
195
- } else {
196
- return boxed as! NSObject
197
- }
198
- #else
199
- return ( value as AnyObject ) as! NSObject
200
- #endif
190
+ let boxed = ( value as AnyObject )
191
+ if boxed is NSObject {
192
+ return boxed as! NSObject
193
+ } else {
194
+ return __SwiftValue ( value) // Do not emit native boxes — wrap them in Swift Foundation boxes instead.
195
+ }
201
196
}
202
197
}
203
198
You can’t perform that action at this time.
0 commit comments