mirror of
https://github.com/llvm/llvm-project.git
synced 2025-04-17 19:26:36 +00:00

The warning this inhibits, -Wobjc-root-class, is opt-in for now. However, all clang unit tests that would trigger the warning have been updated to use -Wno-objc-root-class. <rdar://problem/7446698> llvm-svn: 154187
13 lines
289 B
Objective-C
13 lines
289 B
Objective-C
// RUN: %clang_cc1 -verify -fsyntax-only -Wno-objc-root-class %s
|
|
|
|
@interface NSView
|
|
- (id)initWithView:(id)realView;
|
|
@end
|
|
|
|
@implementation NSView
|
|
- (id)initWithView:(id)realView {
|
|
*(NSView *)self = *(NSView *)realView; // expected-error {{cannot assign to class object}}
|
|
}
|
|
@end
|
|
|