-
Notifications
You must be signed in to change notification settings - Fork 10.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Warn if forward class is used as a receiver.
llvm-svn: 71278
- Loading branch information
Fariborz Jahanian
committed
May 8, 2009
1 parent
18f026a
commit 1bd844d
Showing
3 changed files
with
24 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// RUN: clang-cc -fsyntax-only -verify %s | ||
|
||
@interface I | ||
+ new; | ||
@end | ||
Class isa; | ||
|
||
@class NotKnown; | ||
|
||
void foo(NotKnown *n) { | ||
[isa new]; | ||
[NotKnown new]; /* expected-warning {{receiver 'NotKnown' is a forward class and corresponding}} */ | ||
} |