Home | History | Annotate | Download | only in SemaObjC
      1 // RUN: %clang_cc1 -verify -fsyntax-only -Wno-objc-root-class %s
      2 
      3 @interface NSView 
      4   - (id)initWithView:(id)realView;
      5 @end
      6 
      7 @implementation NSView
      8  - (id)initWithView:(id)realView {
      9      *(NSView *)self = *(NSView *)realView;	// expected-error {{cannot assign to class object}}
     10  }
     11 @end
     12 
     13