blob: abca5b92aa2795c528a5c583e82e545f66c795cd [file] [log] [blame]
// RUN: %target-swift-frontend -disable-objc-interop -typecheck %s -verify
class C {}
func test(c: AnyClass) {
let _: AnyObject = c // expected-error {{value of type 'AnyClass' (aka 'AnyObject.Type') expected to be instance of class or class-constrained type}}
let _: AnyObject = C.self // expected-error {{value of type 'C.Type' expected to be instance of class or class-constrained type}}
}