mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Also removed the sdk 'feature' in favour of the more specific objc_interop. Swift SVN r24856
21 lines
385 B
Swift
21 lines
385 B
Swift
// RUN: %target-run-simple-swift | FileCheck %s
|
|
|
|
// REQUIRES: objc_interop
|
|
|
|
// Test interop of pure Swift objects as ObjC objects accessed through AnyObject.
|
|
|
|
import Foundation
|
|
|
|
class FullyNative {
|
|
deinit { println("dead") }
|
|
}
|
|
|
|
autoreleasepool {
|
|
let c: AnyObject = FullyNative() as AnyObject
|
|
|
|
// CHECK: {{^}}main.FullyNative{{$}}
|
|
println(c.description!)
|
|
}
|
|
// CHECK-NEXT: dead
|
|
|