[cfe-commits] r54044 - in /cfe/trunk: lib/Parse/ParseObjc.cpp test/Sema/objc-interface-1.m
Chris Lattner
sabre at nondot.org
Fri Jul 25 12:54:55 PDT 2008
Author: lattner
Date: Fri Jul 25 14:54:55 2008
New Revision: 54044
URL: http://llvm.org/viewvc/llvm-project?rev=54044&view=rev
Log:
gcc requires a semicolon at the end of an interface, unlike its extension for structs.
rdar://6095245.
Modified:
cfe/trunk/lib/Parse/ParseObjc.cpp
cfe/trunk/test/Sema/objc-interface-1.m
Modified: cfe/trunk/lib/Parse/ParseObjc.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Parse/ParseObjc.cpp?rev=54044&r1=54043&r2=54044&view=diff
==============================================================================
--- cfe/trunk/lib/Parse/ParseObjc.cpp (original)
+++ cfe/trunk/lib/Parse/ParseObjc.cpp Fri Jul 25 14:54:55 2008
@@ -820,9 +820,6 @@
if (Tok.is(tok::semi)) {
ConsumeToken();
- } else if (Tok.is(tok::r_brace)) {
- Diag(Tok.getLocation(), diag::ext_expected_semi_decl_list);
- break;
} else {
Diag(Tok, diag::err_expected_semi_decl_list);
// Skip to end of block or statement
Modified: cfe/trunk/test/Sema/objc-interface-1.m
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Sema/objc-interface-1.m?rev=54044&r1=54043&r2=54044&view=diff
==============================================================================
--- cfe/trunk/test/Sema/objc-interface-1.m (original)
+++ cfe/trunk/test/Sema/objc-interface-1.m Fri Jul 25 14:54:55 2008
@@ -6,3 +6,12 @@
<NSCopying> // expected-error {{cannot find protocol definition for 'NSCopying'}}
@end
+
+// rdar://6095245
+ at interface A
+{
+ int x
+} // expected-error {{expected ';' at end of declaration list}}
+ at end
+
+
More information about the cfe-commits
mailing list