forked from chapuni/clang
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
HandleDeclarator() returns NULL for semantic disasters. Deal with it
when we're in an Objective-C container context. Fixes <rdar://problem/11286701>. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@155836 91177308-0d34-0410-b5e6-96231b3b80d8
- Loading branch information
1 parent
694e796
commit e7be109
Showing
2 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
// RUN: %clang_cc1 -fsyntax-only %s -verify | ||
|
||
// <rdar://problem/11286701> | ||
namespace std { | ||
template<typename T, typename U> class pair; | ||
} | ||
|
||
@interface NSObject | ||
@end | ||
|
||
@interface Test : NSObject | ||
@end | ||
|
||
@implementation Test | ||
|
||
struct EvilStruct { | ||
} // note the missing semicolon | ||
|
||
typedef std::pair<int, int> IntegerPair; // expected-error{{typedef declarator cannot be qualified}} \ | ||
// expected-error{{typedef name must be an identifier}} \ | ||
// expected-error{{expected ';' after top level declarator}} | ||
|
||
@end |