[llvm-branch-commits] [cfe-branch] r154919 [2/2] - in /cfe/branches/tooling: ./ INPUTS/ docs/ examples/clang-interpreter/ include/clang-c/ include/clang/AST/ include/clang/Analysis/ include/clang/Basic/ include/clang/Config/ include/clang/Driver/ include/clang/Frontend/ include/clang/Index/ include/clang/Lex/ include/clang/Parse/ include/clang/Sema/ include/clang/StaticAnalyzer/Checkers/ include/clang/StaticAnalyzer/Core/ include/clang/StaticAnalyzer/Core/BugReporter/ include/clang/StaticAnalyzer/Core/PathSensitive/ include/c...

Manuel Klimek klimek at google.com
Tue Apr 17 04:08:29 PDT 2012


Modified: cfe/branches/tooling/test/SemaObjC/method-unused-attribute.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/method-unused-attribute.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/method-unused-attribute.m (original)
+++ cfe/branches/tooling/test/SemaObjC/method-unused-attribute.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1  -fsyntax-only -Wunused-parameter -verify %s
+// RUN: %clang_cc1  -fsyntax-only -Wunused-parameter -verify -Wno-objc-root-class %s
 
 @interface INTF
 - (void) correct_use_of_unused: (void *) notice : (id)another_arg;

Modified: cfe/branches/tooling/test/SemaObjC/missing-atend-metadata.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/missing-atend-metadata.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/missing-atend-metadata.m (original)
+++ cfe/branches/tooling/test/SemaObjC/missing-atend-metadata.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -triple i386-apple-darwin9 -fsyntax-only -verify %s 
+// RUN: %clang_cc1 -triple i386-apple-darwin9 -fsyntax-only -verify -Wno-objc-root-class %s 
 
 @interface I0 
 @end

Modified: cfe/branches/tooling/test/SemaObjC/missing-method-return-type.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/missing-method-return-type.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/missing-method-return-type.m (original)
+++ cfe/branches/tooling/test/SemaObjC/missing-method-return-type.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -Wmissing-method-return-type -fsyntax-only -verify %s
+// RUN: %clang_cc1 -Wmissing-method-return-type -fsyntax-only -verify -Wno-objc-root-class %s
 // rdar://9615045
 
 @interface I

Modified: cfe/branches/tooling/test/SemaObjC/nested-typedef-decl.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/nested-typedef-decl.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/nested-typedef-decl.m (original)
+++ cfe/branches/tooling/test/SemaObjC/nested-typedef-decl.m Tue Apr 17 06:08:26 2012
@@ -1,5 +1,5 @@
-// RUN: %clang_cc1 -x objective-c -fsyntax-only -verify %s
-// RUN: %clang_cc1 -x objective-c++ -fsyntax-only -verify %s
+// RUN: %clang_cc1 -x objective-c -fsyntax-only -verify -Wno-objc-root-class %s
+// RUN: %clang_cc1 -x objective-c++ -fsyntax-only -verify -Wno-objc-root-class %s
 // rdar://10041908
 
 @interface Bar {

Modified: cfe/branches/tooling/test/SemaObjC/newproperty-class-method-1.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/newproperty-class-method-1.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/newproperty-class-method-1.m (original)
+++ cfe/branches/tooling/test/SemaObjC/newproperty-class-method-1.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 %s -verify -fsyntax-only
+// RUN: %clang_cc1 -verify -fsyntax-only -Wno-objc-root-class %s
 
 void abort(void);
 

Modified: cfe/branches/tooling/test/SemaObjC/no-gc-weak-test.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/no-gc-weak-test.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/no-gc-weak-test.m (original)
+++ cfe/branches/tooling/test/SemaObjC/no-gc-weak-test.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -triple i386-apple-darwin9 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -triple i386-apple-darwin9 -fsyntax-only -verify -Wno-objc-root-class %s
 
 @interface Subtask
 {

Modified: cfe/branches/tooling/test/SemaObjC/no-ivar-access-control.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/no-ivar-access-control.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/no-ivar-access-control.m (original)
+++ cfe/branches/tooling/test/SemaObjC/no-ivar-access-control.m Tue Apr 17 06:08:26 2012
@@ -1,5 +1,5 @@
-// RUN: %clang_cc1 -fsyntax-only -fdebugger-support -verify %s
-// RUN: %clang_cc1 -x objective-c++ -fdebugger-support -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -fdebugger-support -verify -Wno-objc-root-class %s
+// RUN: %clang_cc1 -x objective-c++ -fdebugger-support -fsyntax-only -verify -Wno-objc-root-class %s
 // rdar://10997647
 
 @interface I

Modified: cfe/branches/tooling/test/SemaObjC/no-protocol-option-tests.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/no-protocol-option-tests.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/no-protocol-option-tests.m (original)
+++ cfe/branches/tooling/test/SemaObjC/no-protocol-option-tests.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -Wno-protocol -verify %s
+// RUN: %clang_cc1 -fsyntax-only -Wno-protocol -verify -Wno-objc-root-class %s
 // rdar: // 7056600
 
 @protocol P

Modified: cfe/branches/tooling/test/SemaObjC/no-warn-qual-mismatch.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/no-warn-qual-mismatch.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/no-warn-qual-mismatch.m (original)
+++ cfe/branches/tooling/test/SemaObjC/no-warn-qual-mismatch.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1  -fsyntax-only -verify %s
+// RUN: %clang_cc1  -fsyntax-only -verify -Wno-objc-root-class %s
 // radar 7211563
 
 @interface X

Modified: cfe/branches/tooling/test/SemaObjC/no-warn-synth-protocol-meth.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/no-warn-synth-protocol-meth.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/no-warn-synth-protocol-meth.m (original)
+++ cfe/branches/tooling/test/SemaObjC/no-warn-synth-protocol-meth.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1  -fsyntax-only -verify %s
+// RUN: %clang_cc1  -fsyntax-only -verify -Wno-objc-root-class %s
 
 @protocol CYCdef
 - (int)name;

Modified: cfe/branches/tooling/test/SemaObjC/no-warning-unavail-unimp.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/no-warning-unavail-unimp.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/no-warning-unavail-unimp.m (original)
+++ cfe/branches/tooling/test/SemaObjC/no-warning-unavail-unimp.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1  -fsyntax-only -verify %s
+// RUN: %clang_cc1  -fsyntax-only -verify -Wno-objc-root-class %s
 // rdar://9651605
 
 @interface Foo

Modified: cfe/branches/tooling/test/SemaObjC/nonnull.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/nonnull.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/nonnull.m (original)
+++ cfe/branches/tooling/test/SemaObjC/nonnull.m Tue Apr 17 06:08:26 2012
@@ -1,6 +1,6 @@
 #include "nonnull.h"
 
-// RUN: %clang_cc1 -fblocks -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fblocks -fsyntax-only -verify -Wno-objc-root-class %s
 
 @class NSObject;
 

Modified: cfe/branches/tooling/test/SemaObjC/nsobject-attribute-1.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/nsobject-attribute-1.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/nsobject-attribute-1.m (original)
+++ cfe/branches/tooling/test/SemaObjC/nsobject-attribute-1.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fblocks -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fblocks -fsyntax-only -verify -Wno-objc-root-class %s
 
 @interface NSObject
 - (id)self;

Modified: cfe/branches/tooling/test/SemaObjC/nsobject-attribute.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/nsobject-attribute.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/nsobject-attribute.m (original)
+++ cfe/branches/tooling/test/SemaObjC/nsobject-attribute.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 
 typedef struct CGColor * __attribute__ ((NSObject)) CGColorRef;
 static int count;

Modified: cfe/branches/tooling/test/SemaObjC/objc-buffered-methods.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/objc-buffered-methods.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/objc-buffered-methods.m (original)
+++ cfe/branches/tooling/test/SemaObjC/objc-buffered-methods.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 // rdar://8843851
 
 int* global;

Modified: cfe/branches/tooling/test/SemaObjC/objc-cstyle-args-in-methods.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/objc-cstyle-args-in-methods.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/objc-cstyle-args-in-methods.m (original)
+++ cfe/branches/tooling/test/SemaObjC/objc-cstyle-args-in-methods.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1  -fsyntax-only -verify %s
+// RUN: %clang_cc1  -fsyntax-only -verify -Wno-objc-root-class %s
 
 @interface Foo 
 - (id)test:(id)one, id two;

Modified: cfe/branches/tooling/test/SemaObjC/objc-literal-nsnumber.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/objc-literal-nsnumber.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/objc-literal-nsnumber.m (original)
+++ cfe/branches/tooling/test/SemaObjC/objc-literal-nsnumber.m Tue Apr 17 06:08:26 2012
@@ -76,3 +76,10 @@
                                @"date" : [NSDate date] };
   return dictionary3;
 }
+
+// rdar:// 11231426
+typedef float BOOL; // expected-note {{previous declaration is here}}
+
+BOOL radar11231426() {
+        return __objc_yes; // expected-warning {{BOOL of type 'float' is non-intergal and unsuitable for a boolean literal - ignored}}
+}

Modified: cfe/branches/tooling/test/SemaObjC/objc-qualified-property-lookup.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/objc-qualified-property-lookup.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/objc-qualified-property-lookup.m (original)
+++ cfe/branches/tooling/test/SemaObjC/objc-qualified-property-lookup.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1  -fsyntax-only -verify %s
+// RUN: %clang_cc1  -fsyntax-only -verify -Wno-objc-root-class %s
 // rdar://9078584
 
 @interface NSObject @end

Modified: cfe/branches/tooling/test/SemaObjC/pedantic-dynamic-test.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/pedantic-dynamic-test.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/pedantic-dynamic-test.m (original)
+++ cfe/branches/tooling/test/SemaObjC/pedantic-dynamic-test.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify -pedantic %s
+// RUN: %clang_cc1 -fsyntax-only -verify -pedantic -Wno-objc-root-class %s
 // rdar: // 7860960
 
 @interface I

Modified: cfe/branches/tooling/test/SemaObjC/pragma-pack.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/pragma-pack.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/pragma-pack.m (original)
+++ cfe/branches/tooling/test/SemaObjC/pragma-pack.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -triple i686-apple-darwin9 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -triple i686-apple-darwin9 -fsyntax-only -verify -Wno-objc-root-class %s
 
 // Make sure pragma pack works inside ObjC methods.  <rdar://problem/10893316>
 @interface X

Modified: cfe/branches/tooling/test/SemaObjC/property-2.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property-2.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property-2.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property-2.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 
 @interface Tester 
 @property char PropertyAtomic_char;

Modified: cfe/branches/tooling/test/SemaObjC/property-9.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property-9.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property-9.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property-9.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 
 typedef signed char BOOL;
 @protocol NSObject  - (BOOL)isEqual:(id)object; @end

Modified: cfe/branches/tooling/test/SemaObjC/property-and-ivar-use.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property-and-ivar-use.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property-and-ivar-use.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property-and-ivar-use.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 // Do not issue error if 'ivar' used previously belongs to the inherited class
 // and has same name as @dynalic property in current class.
 

Modified: cfe/branches/tooling/test/SemaObjC/property-category-1.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property-category-1.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property-category-1.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property-category-1.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 
 @interface Object
 + (id)new;

Modified: cfe/branches/tooling/test/SemaObjC/property-category-3.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property-category-3.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property-category-3.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property-category-3.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 
 @protocol P
   @property(readonly) int X; // expected-note {{property declared here}}

Modified: cfe/branches/tooling/test/SemaObjC/property-category-4.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property-category-4.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property-category-4.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property-category-4.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 
 @interface IDELogNavigator
 {

Modified: cfe/branches/tooling/test/SemaObjC/property-category-impl.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property-category-impl.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property-category-impl.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property-category-impl.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 
 /* This test is for categories which don't implement the accessors but some accessors are
    implemented in their base class implementation. In this case,no warning must be issued.

Modified: cfe/branches/tooling/test/SemaObjC/property-dot-receiver.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property-dot-receiver.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property-dot-receiver.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property-dot-receiver.m Tue Apr 17 06:08:26 2012
@@ -1,5 +1,5 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s 
-// RUN: %clang_cc1 -x objective-c++ -fsyntax-only -verify %s 
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s 
+// RUN: %clang_cc1 -x objective-c++ -fsyntax-only -verify -Wno-objc-root-class %s 
 // rdar://8962253
 
 @interface Singleton {

Modified: cfe/branches/tooling/test/SemaObjC/property-expression-error.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property-expression-error.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property-expression-error.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property-expression-error.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1  -fsyntax-only -verify %s
+// RUN: %clang_cc1  -fsyntax-only -verify -Wno-objc-root-class %s
 
 @interface AddressMyProperties 
 {

Modified: cfe/branches/tooling/test/SemaObjC/property-impl-misuse.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property-impl-misuse.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property-impl-misuse.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property-impl-misuse.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 
 @interface I {
   int Y;

Modified: cfe/branches/tooling/test/SemaObjC/property-in-class-extension.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property-in-class-extension.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property-in-class-extension.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property-in-class-extension.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1  -fsyntax-only -verify %s
+// RUN: %clang_cc1  -fsyntax-only -verify -Wno-objc-root-class %s
 // rdar://7766184
 
 @interface Foo @end

Modified: cfe/branches/tooling/test/SemaObjC/property-ivar-mismatch.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property-ivar-mismatch.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property-ivar-mismatch.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property-ivar-mismatch.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 // Test that arithmatic types on property and its ivar have exact match.
 
 @interface Test4 

Modified: cfe/branches/tooling/test/SemaObjC/property-lookup-in-id.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property-lookup-in-id.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property-lookup-in-id.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property-lookup-in-id.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1  -fsyntax-only -verify %s
+// RUN: %clang_cc1  -fsyntax-only -verify -Wno-objc-root-class %s
 // rdar://9106929
 
 typedef struct objc_class *Class;

Modified: cfe/branches/tooling/test/SemaObjC/property-method-lookup-impl.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property-method-lookup-impl.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property-method-lookup-impl.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property-method-lookup-impl.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1  -fsyntax-only -verify %s
+// RUN: %clang_cc1  -fsyntax-only -verify -Wno-objc-root-class %s
 
 @interface SSyncCEList
 {

Modified: cfe/branches/tooling/test/SemaObjC/property-not-lvalue.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property-not-lvalue.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property-not-lvalue.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property-not-lvalue.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 
 typedef struct NSSize {
      		int width;

Modified: cfe/branches/tooling/test/SemaObjC/property-ns-returns-not-retained-attr.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property-ns-returns-not-retained-attr.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property-ns-returns-not-retained-attr.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property-ns-returns-not-retained-attr.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -triple x86_64-apple-darwin11 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -triple x86_64-apple-darwin11 -fsyntax-only -verify -Wno-objc-root-class %s
 // rdar://9636091
 
 @interface I

Modified: cfe/branches/tooling/test/SemaObjC/property-redundant-decl-accessor.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property-redundant-decl-accessor.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property-redundant-decl-accessor.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property-redundant-decl-accessor.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -Werror -verify %s
+// RUN: %clang_cc1 -fsyntax-only -Werror -verify -Wno-objc-root-class %s
 
 @interface MyClass {
     const char	*_myName;

Modified: cfe/branches/tooling/test/SemaObjC/property-typecheck-1.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property-typecheck-1.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property-typecheck-1.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property-typecheck-1.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 
 @interface A
 -(float) x;	// expected-note {{declared here}}

Modified: cfe/branches/tooling/test/SemaObjC/property-user-setter.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property-user-setter.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property-user-setter.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property-user-setter.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 
 @interface I0 
 @property(readonly) int x;

Modified: cfe/branches/tooling/test/SemaObjC/property.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/property.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/property.m (original)
+++ cfe/branches/tooling/test/SemaObjC/property.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -triple i386-apple-darwin9 -fobjc-fragile-abi -fsyntax-only -verify %s
+// RUN: %clang_cc1 -triple i386-apple-darwin9 -fobjc-fragile-abi -fsyntax-only -verify -Wno-objc-root-class %s
 
 @interface I 
 {

Modified: cfe/branches/tooling/test/SemaObjC/protocol-archane.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/protocol-archane.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/protocol-archane.m (original)
+++ cfe/branches/tooling/test/SemaObjC/protocol-archane.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 // rdar://5986251
 
 @protocol SomeProtocol

Modified: cfe/branches/tooling/test/SemaObjC/protocol-id-test-1.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/protocol-id-test-1.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/protocol-id-test-1.m (original)
+++ cfe/branches/tooling/test/SemaObjC/protocol-id-test-1.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -verify %s
+// RUN: %clang_cc1 -verify -Wno-objc-root-class %s
 
 @interface FF
 - (void) Meth;

Modified: cfe/branches/tooling/test/SemaObjC/protocol-id-test-2.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/protocol-id-test-2.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/protocol-id-test-2.m (original)
+++ cfe/branches/tooling/test/SemaObjC/protocol-id-test-2.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -verify %s
+// RUN: %clang_cc1 -verify -Wno-objc-root-class %s
 
 @protocol P
 @end

Modified: cfe/branches/tooling/test/SemaObjC/provisional-ivar-lookup.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/provisional-ivar-lookup.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/provisional-ivar-lookup.m (original)
+++ cfe/branches/tooling/test/SemaObjC/provisional-ivar-lookup.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1  -fsyntax-only -fobjc-default-synthesize-properties -verify %s
+// RUN: %clang_cc1  -fsyntax-only -fobjc-default-synthesize-properties -verify -Wno-objc-root-class %s
 
 // rdar:// 8565343
 @interface Foo  {

Modified: cfe/branches/tooling/test/SemaObjC/qualified-protocol-method-conflicts.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/qualified-protocol-method-conflicts.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/qualified-protocol-method-conflicts.m (original)
+++ cfe/branches/tooling/test/SemaObjC/qualified-protocol-method-conflicts.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1  -Woverriding-method-mismatch -fsyntax-only -verify %s
+// RUN: %clang_cc1  -Woverriding-method-mismatch -fsyntax-only -verify -Wno-objc-root-class %s
 // rdar://6191214
 
 @protocol Xint

Modified: cfe/branches/tooling/test/SemaObjC/related-result-type-inference.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/related-result-type-inference.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/related-result-type-inference.m (original)
+++ cfe/branches/tooling/test/SemaObjC/related-result-type-inference.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -verify %s
+// RUN: %clang_cc1 -verify -Wno-objc-root-class %s
 
 @interface Unrelated
 @end

Modified: cfe/branches/tooling/test/SemaObjC/return.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/return.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/return.m (original)
+++ cfe/branches/tooling/test/SemaObjC/return.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 %s -fsyntax-only -verify -Wmissing-noreturn -fobjc-exceptions
+// RUN: %clang_cc1 -fsyntax-only -verify -Wmissing-noreturn -fobjc-exceptions -Wno-objc-root-class %s
 
 int test1() {
   id a;

Modified: cfe/branches/tooling/test/SemaObjC/scope-check.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/scope-check.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/scope-check.m (original)
+++ cfe/branches/tooling/test/SemaObjC/scope-check.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify -fobjc-exceptions %s
+// RUN: %clang_cc1 -fsyntax-only -verify -fobjc-exceptions -Wno-objc-root-class %s
 
 @class A, B, C;
 

Modified: cfe/branches/tooling/test/SemaObjC/selector-3.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/selector-3.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/selector-3.m (original)
+++ cfe/branches/tooling/test/SemaObjC/selector-3.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1  -fsyntax-only -Wselector -verify %s
+// RUN: %clang_cc1  -fsyntax-only -Wselector -verify -Wno-objc-root-class %s
 // rdar://8851684
 
 @interface Foo

Modified: cfe/branches/tooling/test/SemaObjC/selector-error.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/selector-error.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/selector-error.m (original)
+++ cfe/branches/tooling/test/SemaObjC/selector-error.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1  -fsyntax-only -verify %s
+// RUN: %clang_cc1  -fsyntax-only -verify -Wno-objc-root-class %s
 
 @interface Foo
 - (char*) foo;

Modified: cfe/branches/tooling/test/SemaObjC/self-assign.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/self-assign.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/self-assign.m (original)
+++ cfe/branches/tooling/test/SemaObjC/self-assign.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 @interface A
 @end
 

Modified: cfe/branches/tooling/test/SemaObjC/self-declared-in-block.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/self-declared-in-block.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/self-declared-in-block.m (original)
+++ cfe/branches/tooling/test/SemaObjC/self-declared-in-block.m Tue Apr 17 06:08:26 2012
@@ -1,5 +1,5 @@
-// RUN: %clang_cc1 -fsyntax-only -triple x86_64-apple-darwin10  -fblocks -verify %s 
-// RUN: %clang_cc1 -x objective-c++ -fsyntax-only -triple x86_64-apple-darwin10  -fblocks -verify %s 
+// RUN: %clang_cc1 -fsyntax-only -triple x86_64-apple-darwin10  -fblocks -verify -Wno-objc-root-class %s 
+// RUN: %clang_cc1 -x objective-c++ -fsyntax-only -triple x86_64-apple-darwin10  -fblocks -verify -Wno-objc-root-class %s 
 // rdar://9154582
 
 @interface Blocky @end

Modified: cfe/branches/tooling/test/SemaObjC/severe-syntax-error.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/severe-syntax-error.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/severe-syntax-error.m (original)
+++ cfe/branches/tooling/test/SemaObjC/severe-syntax-error.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 // rdar://10633434
 
 @interface testClass

Modified: cfe/branches/tooling/test/SemaObjC/sizeof-interface.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/sizeof-interface.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/sizeof-interface.m (original)
+++ cfe/branches/tooling/test/SemaObjC/sizeof-interface.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -verify -fsyntax-only %s
+// RUN: %clang_cc1 -verify -fsyntax-only -Wno-objc-root-class %s
 
 @class I0; // expected-note 2{{forward declaration of class here}}
 

Modified: cfe/branches/tooling/test/SemaObjC/stand-alone-implementation.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/stand-alone-implementation.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/stand-alone-implementation.m (original)
+++ cfe/branches/tooling/test/SemaObjC/stand-alone-implementation.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 // radar 7547942
 // Allow injection of ivars into implementation's implicit class.
 

Modified: cfe/branches/tooling/test/SemaObjC/synchronized.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/synchronized.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/synchronized.m (original)
+++ cfe/branches/tooling/test/SemaObjC/synchronized.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 
 @interface PBXTrackableTaskManager @end
 

Modified: cfe/branches/tooling/test/SemaObjC/synth-provisional-ivars-1.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/synth-provisional-ivars-1.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/synth-provisional-ivars-1.m (original)
+++ cfe/branches/tooling/test/SemaObjC/synth-provisional-ivars-1.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -fobjc-default-synthesize-properties -verify %s
+// RUN: %clang_cc1 -fsyntax-only -fobjc-default-synthesize-properties -verify -Wno-objc-root-class %s
 // rdar://8913053
 
 typedef unsigned char BOOL;

Modified: cfe/branches/tooling/test/SemaObjC/synth-provisional-ivars.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/synth-provisional-ivars.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/synth-provisional-ivars.m (original)
+++ cfe/branches/tooling/test/SemaObjC/synth-provisional-ivars.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -fobjc-default-synthesize-properties -verify %s
+// RUN: %clang_cc1 -fsyntax-only -fobjc-default-synthesize-properties -verify -Wno-objc-root-class %s
 
 int bar;
 

Modified: cfe/branches/tooling/test/SemaObjC/synthesize-setter-contclass.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/synthesize-setter-contclass.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/synthesize-setter-contclass.m (original)
+++ cfe/branches/tooling/test/SemaObjC/synthesize-setter-contclass.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1  -fsyntax-only -verify %s
+// RUN: %clang_cc1  -fsyntax-only -verify -Wno-objc-root-class %s
 
 @interface TestClass 
 {

Modified: cfe/branches/tooling/test/SemaObjC/synthesized-ivar.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/synthesized-ivar.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/synthesized-ivar.m (original)
+++ cfe/branches/tooling/test/SemaObjC/synthesized-ivar.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -fobjc-default-synthesize-properties -verify %s
+// RUN: %clang_cc1 -fsyntax-only -fobjc-default-synthesize-properties -verify -Wno-objc-root-class %s
 @interface I
 {
 }

Modified: cfe/branches/tooling/test/SemaObjC/transparent-union.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/transparent-union.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/transparent-union.m (original)
+++ cfe/branches/tooling/test/SemaObjC/transparent-union.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1  -fsyntax-only -verify %s
+// RUN: %clang_cc1  -fsyntax-only -verify -Wno-objc-root-class %s
 
 typedef union {
  struct xx_object_s *_do;

Modified: cfe/branches/tooling/test/SemaObjC/undeclared-selector.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/undeclared-selector.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/undeclared-selector.m (original)
+++ cfe/branches/tooling/test/SemaObjC/undeclared-selector.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1  -fsyntax-only -Wundeclared-selector -verify %s
+// RUN: %clang_cc1  -fsyntax-only -Wundeclared-selector -verify -Wno-objc-root-class %s
 
 typedef struct objc_selector *SEL;
 

Modified: cfe/branches/tooling/test/SemaObjC/undef-protocol-methods-1.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/undef-protocol-methods-1.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/undef-protocol-methods-1.m (original)
+++ cfe/branches/tooling/test/SemaObjC/undef-protocol-methods-1.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 
 @protocol P1
 - (void) P1proto;  // expected-note {{method 'P1proto' declared here}}

Modified: cfe/branches/tooling/test/SemaObjC/undef-superclass-1.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/undef-superclass-1.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/undef-superclass-1.m (original)
+++ cfe/branches/tooling/test/SemaObjC/undef-superclass-1.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 
 @class SUPER, Y; // expected-note 2 {{forward declaration of class here}}
 

Modified: cfe/branches/tooling/test/SemaObjC/unimplemented-protocol-prop.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/unimplemented-protocol-prop.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/unimplemented-protocol-prop.m (original)
+++ cfe/branches/tooling/test/SemaObjC/unimplemented-protocol-prop.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1  -fsyntax-only -verify %s
+// RUN: %clang_cc1  -fsyntax-only -verify -Wno-objc-root-class %s
 
 @protocol PROTOCOL0
 @required

Modified: cfe/branches/tooling/test/SemaObjC/unused.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/unused.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/unused.m (original)
+++ cfe/branches/tooling/test/SemaObjC/unused.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 %s -verify -Wunused -Wunused-parameter -fsyntax-only
+// RUN: %clang_cc1 -verify -Wunused -Wunused-parameter -fsyntax-only -Wno-objc-root-class %s
 
 int printf(const char *, ...);
 

Modified: cfe/branches/tooling/test/SemaObjC/warn-deprecated-implementations.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/warn-deprecated-implementations.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/warn-deprecated-implementations.m (original)
+++ cfe/branches/tooling/test/SemaObjC/warn-deprecated-implementations.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -Wdeprecated-implementations -verify %s
+// RUN: %clang_cc1 -fsyntax-only -Wdeprecated-implementations -verify -Wno-objc-root-class %s
 // rdar://8973810
 
 @protocol P

Modified: cfe/branches/tooling/test/SemaObjC/warn-forward-class-attr-deprecated.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/warn-forward-class-attr-deprecated.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/warn-forward-class-attr-deprecated.m (original)
+++ cfe/branches/tooling/test/SemaObjC/warn-forward-class-attr-deprecated.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 %s -fsyntax-only -verify
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 // rdar://10290322
 
 @class ABGroupImportFilesScope; // expected-note {{forward declaration of class here}}

Modified: cfe/branches/tooling/test/SemaObjC/warn-implicit-atomic-property.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/warn-implicit-atomic-property.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/warn-implicit-atomic-property.m (original)
+++ cfe/branches/tooling/test/SemaObjC/warn-implicit-atomic-property.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -Wimplicit-atomic-properties -fobjc-default-synthesize-properties -verify %s
+// RUN: %clang_cc1 -fsyntax-only -Wimplicit-atomic-properties -fobjc-default-synthesize-properties -verify -Wno-objc-root-class %s
 // rdar://8774580
 
 @interface Super

Modified: cfe/branches/tooling/test/SemaObjC/warn-missing-super.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/warn-missing-super.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/warn-missing-super.m (original)
+++ cfe/branches/tooling/test/SemaObjC/warn-missing-super.m Tue Apr 17 06:08:26 2012
@@ -1,5 +1,6 @@
 @protocol NSCopying @end
 
+__attribute__((objc_root_class))
 @interface NSObject <NSCopying>
 - (void)dealloc;
 @end
@@ -40,18 +41,18 @@
 @end
 
 // RUN: %clang_cc1 -fsyntax-only %s 2>&1 | FileCheck %s
-// CHECK: warn-missing-super.m:23:1: warning: method possibly missing a [super dealloc] call
+// CHECK: warn-missing-super.m:24:1: warning: method possibly missing a [super dealloc] call
 // CHECK: 1 warning generated.
 
 // RUN: %clang_cc1 -fsyntax-only -fobjc-gc %s 2>&1 | FileCheck --check-prefix=CHECK-GC %s
-// CHECK-GC: warn-missing-super.m:23:1: warning: method possibly missing a [super dealloc] call
-// CHECK-GC: warn-missing-super.m:25:1: warning: method possibly missing a [super finalize] call
+// CHECK-GC: warn-missing-super.m:24:1: warning: method possibly missing a [super dealloc] call
+// CHECK-GC: warn-missing-super.m:26:1: warning: method possibly missing a [super finalize] call
 // CHECK-GC: 2 warnings generated.
 
 // RUN: %clang_cc1 -fsyntax-only -fobjc-gc-only %s 2>&1 | FileCheck --check-prefix=CHECK-GC-ONLY %s
-// CHECK-GC-ONLY: warn-missing-super.m:25:1: warning: method possibly missing a [super finalize] call
+// CHECK-GC-ONLY: warn-missing-super.m:26:1: warning: method possibly missing a [super finalize] call
 // CHECK-GC-ONLY: 1 warning generated.
 
 // RUN: %clang_cc1 -fsyntax-only -triple x86_64-apple-darwin10 -fobjc-arc %s 2>&1 | FileCheck --check-prefix=CHECK-ARC %s
-// CHECK-ARC: warn-missing-super.m:35:4: error: ARC forbids explicit message send of 'dealloc'
+// CHECK-ARC: warn-missing-super.m:36:4: error: ARC forbids explicit message send of 'dealloc'
 // CHECK-ARC: 1 error generated.

Modified: cfe/branches/tooling/test/SemaObjC/warn-retain-cycle.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/warn-retain-cycle.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/warn-retain-cycle.m (original)
+++ cfe/branches/tooling/test/SemaObjC/warn-retain-cycle.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -fobjc-runtime-has-weak -fobjc-arc -fblocks -verify %s
+// RUN: %clang_cc1 -fsyntax-only -fobjc-runtime-has-weak -fobjc-arc -fblocks -verify -Wno-objc-root-class %s
 
 @interface Test0
 - (void) setBlock: (void(^)(void)) block;

Modified: cfe/branches/tooling/test/SemaObjC/warn-weak-field.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/warn-weak-field.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/warn-weak-field.m (original)
+++ cfe/branches/tooling/test/SemaObjC/warn-weak-field.m Tue Apr 17 06:08:26 2012
@@ -1,5 +1,5 @@
-// RUN: %clang_cc1 -triple i386-apple-darwin9 -fsyntax-only -fobjc-gc -verify %s
-// RUN: %clang_cc1 -x objective-c++ -triple i386-apple-darwin9 -fsyntax-only -fobjc-gc -verify %s
+// RUN: %clang_cc1 -triple i386-apple-darwin9 -fsyntax-only -fobjc-gc -verify -Wno-objc-root-class %s
+// RUN: %clang_cc1 -x objective-c++ -triple i386-apple-darwin9 -fsyntax-only -fobjc-gc -verify -Wno-objc-root-class %s
 
 struct S {
 	__weak id w; // expected-warning {{__weak attribute cannot be specified on a field declaration}}

Modified: cfe/branches/tooling/test/SemaObjC/weak-property.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjC/weak-property.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjC/weak-property.m (original)
+++ cfe/branches/tooling/test/SemaObjC/weak-property.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1  -fsyntax-only -fobjc-runtime-has-weak -fobjc-arc -verify %s
+// RUN: %clang_cc1  -fsyntax-only -fobjc-runtime-has-weak -fobjc-arc -verify -Wno-objc-root-class %s
 // rdar://8899430
 
 @interface WeakPropertyTest {

Modified: cfe/branches/tooling/test/SemaObjCXX/arc-overloading.mm
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/arc-overloading.mm?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/arc-overloading.mm (original)
+++ cfe/branches/tooling/test/SemaObjCXX/arc-overloading.mm Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fobjc-runtime-has-weak -fsyntax-only -fobjc-arc -verify -fblocks %s
+// RUN: %clang_cc1 -fobjc-runtime-has-weak -fsyntax-only -fobjc-arc -verify -fblocks -Wno-objc-root-class %s
 
 // Simple ownership conversions + diagnostics.
 int &f0(id __strong const *); // expected-note{{candidate function not viable: 1st argument ('__weak id *') has __weak ownership, but parameter has __strong ownership}}

Modified: cfe/branches/tooling/test/SemaObjCXX/blocks.mm
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/blocks.mm?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/blocks.mm (original)
+++ cfe/branches/tooling/test/SemaObjCXX/blocks.mm Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify -fblocks %s
+// RUN: %clang_cc1 -fsyntax-only -verify -fblocks -Wno-objc-root-class %s
 @protocol NSObject;
 
 void bar(id(^)(void));

Modified: cfe/branches/tooling/test/SemaObjCXX/composite-objc-pointertype.mm
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/composite-objc-pointertype.mm?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/composite-objc-pointertype.mm (original)
+++ cfe/branches/tooling/test/SemaObjCXX/composite-objc-pointertype.mm Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 
 @interface Foo
 @end

Modified: cfe/branches/tooling/test/SemaObjCXX/cstyle-block-pointer-cast.mm
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/cstyle-block-pointer-cast.mm?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/cstyle-block-pointer-cast.mm (original)
+++ cfe/branches/tooling/test/SemaObjCXX/cstyle-block-pointer-cast.mm Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify -fblocks %s
+// RUN: %clang_cc1 -fsyntax-only -verify -fblocks -Wno-objc-root-class %s
 // radar 7562285
 
 typedef int (^blocktype)(int a, int b);

Modified: cfe/branches/tooling/test/SemaObjCXX/cxxoperator-selector.mm
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/cxxoperator-selector.mm?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/cxxoperator-selector.mm (original)
+++ cfe/branches/tooling/test/SemaObjCXX/cxxoperator-selector.mm Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 // rdar:// 8328250
 
 @class NSDate;

Modified: cfe/branches/tooling/test/SemaObjCXX/fragile-abi-object-assign.m
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/fragile-abi-object-assign.m?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/fragile-abi-object-assign.m (original)
+++ cfe/branches/tooling/test/SemaObjCXX/fragile-abi-object-assign.m Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -x objective-c++ -triple x86_64-apple-darwin11 -fsyntax-only -fobjc-fragile-abi -verify %s
+// RUN: %clang_cc1 -x objective-c++ -triple x86_64-apple-darwin11 -fsyntax-only -fobjc-fragile-abi -verify -Wno-objc-root-class %s
 // rdar://10731065
 
 @interface MyView {}

Modified: cfe/branches/tooling/test/SemaObjCXX/goto.mm
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/goto.mm?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/goto.mm (original)
+++ cfe/branches/tooling/test/SemaObjCXX/goto.mm Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 
 // PR9495
 struct NonPOD { NonPOD(); ~NonPOD(); };

Modified: cfe/branches/tooling/test/SemaObjCXX/instantiate-method-return.mm
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/instantiate-method-return.mm?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/instantiate-method-return.mm (original)
+++ cfe/branches/tooling/test/SemaObjCXX/instantiate-method-return.mm Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 // PR7386
 
 @class NSObject;

Modified: cfe/branches/tooling/test/SemaObjCXX/ivar-construct.mm
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/ivar-construct.mm?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/ivar-construct.mm (original)
+++ cfe/branches/tooling/test/SemaObjCXX/ivar-construct.mm Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 struct Y { 
   Y(); 
 

Modified: cfe/branches/tooling/test/SemaObjCXX/ivar-lookup.mm
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/ivar-lookup.mm?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/ivar-lookup.mm (original)
+++ cfe/branches/tooling/test/SemaObjCXX/ivar-lookup.mm Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 @interface Ivar
 - (float*)method;
 @end

Modified: cfe/branches/tooling/test/SemaObjCXX/literals.mm
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/literals.mm?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/literals.mm (original)
+++ cfe/branches/tooling/test/SemaObjCXX/literals.mm Tue Apr 17 06:08:26 2012
@@ -1,6 +1,15 @@
 // RUN: %clang_cc1 -fsyntax-only -verify -std=c++0x -fblocks %s
 
-typedef unsigned char BOOL;
+// rdar://11231426
+typedef bool BOOL;
+
+void y(BOOL (^foo)());
+
+void x() {
+    y(^{
+        return __objc_yes;
+    });
+}
 
 @protocol NSCopying
 - copy;

Modified: cfe/branches/tooling/test/SemaObjCXX/message.mm
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/message.mm?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/message.mm (original)
+++ cfe/branches/tooling/test/SemaObjCXX/message.mm Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -fobjc-fragile-abi -verify %s
+// RUN: %clang_cc1 -fsyntax-only -fobjc-fragile-abi -verify -Wno-objc-root-class %s
 @interface I1
 - (int*)method;
 @end

Modified: cfe/branches/tooling/test/SemaObjCXX/objc-decls-inside-namespace.mm
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/objc-decls-inside-namespace.mm?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/objc-decls-inside-namespace.mm (original)
+++ cfe/branches/tooling/test/SemaObjCXX/objc-decls-inside-namespace.mm Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 
 namespace C {
 

Modified: cfe/branches/tooling/test/SemaObjCXX/objc-pointer-conv.mm
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/objc-pointer-conv.mm?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/objc-pointer-conv.mm (original)
+++ cfe/branches/tooling/test/SemaObjCXX/objc-pointer-conv.mm Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 
 typedef const void * VoidStar;
 

Modified: cfe/branches/tooling/test/SemaObjCXX/overload.mm
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/overload.mm?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/overload.mm (original)
+++ cfe/branches/tooling/test/SemaObjCXX/overload.mm Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 @interface Foo
 @end
 

Modified: cfe/branches/tooling/test/SemaObjCXX/propert-dot-error.mm
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/propert-dot-error.mm?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/propert-dot-error.mm (original)
+++ cfe/branches/tooling/test/SemaObjCXX/propert-dot-error.mm Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 // rdar: // 8379892
 
 struct X {

Modified: cfe/branches/tooling/test/SemaObjCXX/properties.mm
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/properties.mm?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/properties.mm (original)
+++ cfe/branches/tooling/test/SemaObjCXX/properties.mm Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -std=c++11 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -std=c++11 -fsyntax-only -verify -Wno-objc-root-class %s
 
 struct X { 
   void f() const;

Modified: cfe/branches/tooling/test/SemaObjCXX/property-reference.mm
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/property-reference.mm?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/property-reference.mm (original)
+++ cfe/branches/tooling/test/SemaObjCXX/property-reference.mm Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -x objective-c++ -triple x86_64-apple-darwin10 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -x objective-c++ -triple x86_64-apple-darwin10 -fsyntax-only -verify -Wno-objc-root-class %s
 // rdar://9070460
 
 class TCPPObject
@@ -42,3 +42,18 @@
 	cppObjectNonAtomic = cppObject;
 }
 @end
+
+
+// <rdar://problem/11052352>
+ at interface NSObject
++ alloc;
+- init;
+- class;
+ at end
+
+template<typename T> void f() {
+  NSObject *o = [NSObject.alloc init];
+  [o class];
+}
+
+template void f<int>();

Modified: cfe/branches/tooling/test/SemaObjCXX/property-synthesis-error.mm
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/property-synthesis-error.mm?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/property-synthesis-error.mm (original)
+++ cfe/branches/tooling/test/SemaObjCXX/property-synthesis-error.mm Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 // rdar: //8550657
 
 @interface NSArray @end

Modified: cfe/branches/tooling/test/SemaObjCXX/void_to_obj.mm
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaObjCXX/void_to_obj.mm?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaObjCXX/void_to_obj.mm (original)
+++ cfe/branches/tooling/test/SemaObjCXX/void_to_obj.mm Tue Apr 17 06:08:26 2012
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Wno-objc-root-class %s
 
 // <rdar://problem/6463729>
 @class XX;

Modified: cfe/branches/tooling/test/SemaTemplate/member-template-access-expr.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/SemaTemplate/member-template-access-expr.cpp?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/SemaTemplate/member-template-access-expr.cpp (original)
+++ cfe/branches/tooling/test/SemaTemplate/member-template-access-expr.cpp Tue Apr 17 06:08:26 2012
@@ -60,7 +60,7 @@
 
 void test_X1(X1 x1) {
   float *fp1 = x1.f1<>(17);
-  float *fp2 = x1.f1<int>(3.14);
+  float *fp2 = x1.f1<int>(3.14); // expected-warning {{implicit conversion turns literal floating-point number into integer}}
   int *ip1 = x1.f1(17);
   float *ip2 = x1.f1(3.14);
   

Modified: cfe/branches/tooling/test/lit.cfg
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/test/lit.cfg?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/test/lit.cfg (original)
+++ cfe/branches/tooling/test/lit.cfg Tue Apr 17 06:08:26 2012
@@ -46,6 +46,35 @@
 config.llvm_src_root = getattr(config, 'llvm_src_root', None)
 config.llvm_obj_root = getattr(config, 'llvm_obj_root', None)
 
+# Clear some environment variables that might affect Clang.
+#
+# This first set of vars are read by Clang, but shouldn't affect tests
+# that aren't specifically looking for these features, or are required
+# simply to run the tests at all.
+#
+# FIXME: Should we have a tool that enforces this?
+
+# safe_env_vars = ('TMPDIR', 'TEMP', 'TMP', 'USERPROFILE', 'PWD',
+#                  'MACOSX_DEPLOYMENT_TARGET', 'IPHONEOS_DEPLOYMENT_TARGET',
+#                  'IOS_SIMULATOR_DEPLOYMENT_TARGET',
+#                  'VCINSTALLDIR', 'VC100COMNTOOLS', 'VC90COMNTOOLS',
+#                  'VC80COMNTOOLS')
+possibly_dangerous_env_vars = ['COMPILER_PATH', 'RC_DEBUG_OPTIONS',
+                               'CINDEXTEST_PREAMBLE_FILE', 'LIBRARY_PATH',
+                               'CPATH', 'C_INCLUDE_PATH', 'CPLUS_INCLUDE_PATH',
+                               'OBJC_INCLUDE_PATH', 'OBJCPLUS_INCLUDE_PATH',
+                               'LIBCLANG_TIMING', 'LIBCLANG_OBJTRACKING',
+                               'LIBCLANG_LOGGING', 'LIBCLANG_BGPRIO_INDEX',
+                               'LIBCLANG_BGPRIO_EDIT', 'LIBCLANG_NOTHREADS',
+                               'LIBCLANG_RESOURCE_USAGE',
+                               'LIBCLANG_CODE_COMPLETION_LOGGING']
+# Clang/Win32 may refer to %INCLUDE%. vsvarsall.bat sets it.
+if platform.system() != 'Windows':
+    possibly_dangerous_env_vars.append('INCLUDE')
+for name in possibly_dangerous_env_vars:
+  if name in config.environment:
+    del config.environment[name]
+
 # Tweak the PATH to include the tools dir and the scripts dir.
 if clang_obj_root is not None:
     llvm_tools_dir = getattr(config, 'llvm_tools_dir', None)

Modified: cfe/branches/tooling/tools/arcmt-test/Makefile
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/arcmt-test/Makefile?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/arcmt-test/Makefile (original)
+++ cfe/branches/tooling/tools/arcmt-test/Makefile Tue Apr 17 06:08:26 2012
@@ -17,7 +17,7 @@
 NO_INSTALL = 1
 
 LINK_COMPONENTS := support mc
-USEDLIBS = clangIndex.a clangARCMigrate.a clangRewrite.a \
+USEDLIBS = clangARCMigrate.a clangRewrite.a \
 		 clangFrontend.a clangDriver.a clangSerialization.a clangParse.a \
 		 clangSema.a clangEdit.a clangAnalysis.a clangAST.a clangLex.a clangBasic.a
 

Modified: cfe/branches/tooling/tools/c-arcmt-test/Makefile
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/c-arcmt-test/Makefile?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/c-arcmt-test/Makefile (original)
+++ cfe/branches/tooling/tools/c-arcmt-test/Makefile Tue Apr 17 06:08:26 2012
@@ -17,7 +17,7 @@
 NO_INSTALL = 1
 
 LINK_COMPONENTS := support mc
-USEDLIBS = clang.a clangIndex.a clangARCMigrate.a clangRewrite.a \
+USEDLIBS = clang.a clangARCMigrate.a clangRewrite.a \
 	   clangFrontend.a clangDriver.a \
 	   clangSerialization.a clangParse.a clangSema.a \
 	   clangAnalysis.a clangEdit.a clangAST.a clangLex.a clangBasic.a

Modified: cfe/branches/tooling/tools/c-arcmt-test/c-arcmt-test.c
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/c-arcmt-test/c-arcmt-test.c?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/c-arcmt-test/c-arcmt-test.c (original)
+++ cfe/branches/tooling/tools/c-arcmt-test/c-arcmt-test.c Tue Apr 17 06:08:26 2012
@@ -97,6 +97,9 @@
 void thread_runner(void *client_data_v) {
   thread_info *client_data = client_data_v;
   client_data->result = carcmttest_main(client_data->argc, client_data->argv);
+#ifdef __CYGWIN__
+  fflush(stdout);  /* stdout is not flushed on Cygwin. */
+#endif
 }
 
 int main(int argc, const char **argv) {

Modified: cfe/branches/tooling/tools/c-index-test/Makefile
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/c-index-test/Makefile?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/c-index-test/Makefile (original)
+++ cfe/branches/tooling/tools/c-index-test/Makefile Tue Apr 17 06:08:26 2012
@@ -18,7 +18,7 @@
 TOOL_NO_EXPORTS = 1
 
 LINK_COMPONENTS := support mc
-USEDLIBS = clang.a clangIndex.a clangFrontend.a clangDriver.a \
+USEDLIBS = clang.a clangFrontend.a clangDriver.a \
 	   clangSerialization.a clangParse.a clangSema.a \
 	   clangAnalysis.a clangEdit.a clangAST.a clangLex.a clangBasic.a
 

Modified: cfe/branches/tooling/tools/c-index-test/c-index-test.c
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/c-index-test/c-index-test.c?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/c-index-test/c-index-test.c (original)
+++ cfe/branches/tooling/tools/c-index-test/c-index-test.c Tue Apr 17 06:08:26 2012
@@ -39,6 +39,8 @@
     options |= CXTranslationUnit_CacheCompletionResults;
   if (getenv("CINDEXTEST_COMPLETION_NO_CACHING"))
     options &= ~CXTranslationUnit_CacheCompletionResults;
+  if (getenv("CINDEXTEST_SKIP_FUNCTION_BODIES"))
+    options |= CXTranslationUnit_SkipFunctionBodies;
   
   return options;
 }
@@ -663,6 +665,23 @@
         clang_disposeString(RS);
       }
     }
+    /* Print the argument types if they exist. */
+    {
+      int numArgs = clang_Cursor_getNumArguments(cursor);
+      if (numArgs != -1 && numArgs != 0) {
+        int i;
+        printf(" [args=");
+        for (i = 0; i < numArgs; ++i) {
+          CXType T = clang_getCursorType(clang_Cursor_getArgument(cursor, i));
+          if (T.kind != CXType_Invalid) {
+            CXString S = clang_getTypeKindSpelling(T.kind);
+            printf(" %s", clang_getCString(S));
+            clang_disposeString(S);
+          }
+        }
+        printf("]");
+      }
+    }
     /* Print if this is a non-POD type. */
     printf(" [isPOD=%d]", clang_isPODType(T));
 
@@ -2569,9 +2588,9 @@
     CXSourceLocation DiagLoc;
     CXDiagnostic D;
     CXFile File;
-    CXString FileName, DiagSpelling, DiagOption;
+    CXString FileName, DiagSpelling, DiagOption, DiagCat;
     unsigned line, column, offset;
-    const char *DiagOptionStr = 0;
+    const char *DiagOptionStr = 0, *DiagCatStr = 0;
     
     D = clang_getDiagnosticInSet(Diags, i);
     DiagLoc = clang_getDiagnosticLocation(D);
@@ -2594,6 +2613,12 @@
       fprintf(stderr, " [%s]", DiagOptionStr);
     }
     
+    DiagCat = clang_getDiagnosticCategoryText(D);
+    DiagCatStr = clang_getCString(DiagCat);
+    if (DiagCatStr) {
+      fprintf(stderr, " [%s]", DiagCatStr);
+    }
+    
     fprintf(stderr, "\n");
     
     printRanges(D, indent);
@@ -2781,6 +2806,9 @@
 void thread_runner(void *client_data_v) {
   thread_info *client_data = client_data_v;
   client_data->result = cindextest_main(client_data->argc, client_data->argv);
+#ifdef __CYGWIN__
+  fflush(stdout);  /* stdout is not flushed on Cygwin. */
+#endif
 }
 
 int main(int argc, const char **argv) {

Propchange: cfe/branches/tooling/tools/clang-check/ClangCheck.cpp
------------------------------------------------------------------------------
    svn:eol-style = LF

Propchange: cfe/branches/tooling/tools/clang-check/ClangCheck.cpp
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Tue Apr 17 06:08:26 2012
@@ -0,0 +1,2 @@
+/cfe/branches/type-system-rewrite/tools/clang-check/ClangCheck.cpp:134693-134817
+/cfe/trunk/test/SemaTemplate/tools/clang-check/ClangCheck.cpp:126920

Modified: cfe/branches/tooling/tools/driver/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/driver/CMakeLists.txt?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/driver/CMakeLists.txt (original)
+++ cfe/branches/tooling/tools/driver/CMakeLists.txt Tue Apr 17 06:08:26 2012
@@ -7,7 +7,6 @@
   clangDriver
   clangEdit
   clangFrontend
-  clangIndex
   clangLex
   clangParse
   clangEdit

Modified: cfe/branches/tooling/tools/driver/Makefile
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/driver/Makefile?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/driver/Makefile (original)
+++ cfe/branches/tooling/tools/driver/Makefile Tue Apr 17 06:08:26 2012
@@ -35,7 +35,7 @@
            clangSerialization.a clangCodeGen.a clangParse.a clangSema.a \
            clangStaticAnalyzerFrontend.a clangStaticAnalyzerCheckers.a \
            clangStaticAnalyzerCore.a \
-           clangAnalysis.a clangIndex.a clangARCMigrate.a clangRewrite.a \
+           clangAnalysis.a clangARCMigrate.a clangRewrite.a \
            clangEdit.a clangAST.a clangLex.a clangBasic.a
 
 include $(CLANG_LEVEL)/Makefile

Modified: cfe/branches/tooling/tools/fix-llvm-style/FixLLVMStyle.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/fix-llvm-style/FixLLVMStyle.cpp?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/fix-llvm-style/FixLLVMStyle.cpp (original)
+++ cfe/branches/tooling/tools/fix-llvm-style/FixLLVMStyle.cpp Tue Apr 17 06:08:26 2012
@@ -16,10 +16,12 @@
 #include "clang/Basic/SourceManager.h"
 #include "clang/Frontend/FrontendActions.h"
 #include "clang/Lex/Lexer.h"
+#include "clang/Tooling/CompilationDatabase.h"
 #include "clang/Tooling/Refactoring.h"
 #include "clang/Tooling/Tooling.h"
 #include "llvm/ADT/OwningPtr.h"
 #include "llvm/ADT/Twine.h"
+#include "llvm/Support/CommandLine.h"
 #include "llvm/Support/MemoryBuffer.h"
 #include "llvm/Support/Path.h"
 #include "llvm/Support/Regex.h"
@@ -30,8 +32,10 @@
 
 using namespace clang;
 using namespace clang::ast_matchers;
-using clang::tooling::NewFrontendActionFactory;
+using namespace llvm;
+using clang::tooling::newFrontendActionFactory;
 using clang::tooling::Replacement;
+using clang::tooling::CompilationDatabase;
 
 // FIXME: Pull out helper methods in here into more fitting places.
 
@@ -263,8 +267,23 @@
 } }
 
 
+cl::opt<std::string> BuildPath(
+  cl::Positional,
+  cl::desc("<build-path>"));
+
+cl::list<std::string> SourcePaths(
+  cl::Positional,
+  cl::desc("<source0> [... <sourceN>]"),
+  cl::OneOrMore);
+
 int main(int argc, char **argv) {
-  tooling::RefactoringTool Tool(argc, argv);
+  cl::ParseCommandLineOptions(argc, argv);
+  std::string ErrorMessage;
+  llvm::OwningPtr<CompilationDatabase> Compilations(
+    CompilationDatabase::loadFromDirectory(BuildPath, ErrorMessage));
+  if (!Compilations)
+    llvm::report_fatal_error(ErrorMessage);
+  tooling::RefactoringTool Tool(*Compilations, SourcePaths);
   ast_matchers::MatchFinder Finder;
 
   DeclarationMatcher FunctionMatch = Function(Not(HasReturnType(HasClassDeclaration(
@@ -288,6 +307,6 @@
           Not(Constructor())))
         ),
       new FixLLVMStyle(&Tool.GetReplacements()));
-  return Tool.Run(NewFrontendActionFactory(&Finder));
+  return Tool.Run(newFrontendActionFactory(&Finder));
 }
 

Modified: cfe/branches/tooling/tools/libclang/CIndex.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/libclang/CIndex.cpp?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/libclang/CIndex.cpp (original)
+++ cfe/branches/tooling/tools/libclang/CIndex.cpp Tue Apr 17 06:08:26 2012
@@ -51,6 +51,7 @@
 using namespace clang::cxcursor;
 using namespace clang::cxstring;
 using namespace clang::cxtu;
+using namespace clang::cxindex;
 
 CXTranslationUnit cxtu::MakeCXTranslationUnit(CIndexer *CIdx, ASTUnit *TU) {
   if (!TU)
@@ -111,10 +112,11 @@
   // We want the last character in this location, so we will adjust the
   // location accordingly.
   SourceLocation EndLoc = R.getEnd();
-  if (EndLoc.isValid() && EndLoc.isMacroID())
+  if (EndLoc.isValid() && EndLoc.isMacroID() && !SM.isMacroArgExpansion(EndLoc))
     EndLoc = SM.getExpansionRange(EndLoc).second;
-  if (R.isTokenRange() && !EndLoc.isInvalid() && EndLoc.isFileID()) {
-    unsigned Length = Lexer::MeasureTokenLength(EndLoc, SM, LangOpts);
+  if (R.isTokenRange() && !EndLoc.isInvalid()) {
+    unsigned Length = Lexer::MeasureTokenLength(SM.getSpellingLoc(EndLoc),
+                                                SM, LangOpts);
     EndLoc = EndLoc.getLocWithOffset(Length);
   }
 
@@ -2482,7 +2484,7 @@
                                     unsaved_files, num_unsaved_files,
                                     Options);
 }
-  
+
 struct ParseTranslationUnitInfo {
   CXIndex CIdx;
   const char *source_filename;
@@ -2519,7 +2521,8 @@
     = (options & CXTranslationUnit_Incomplete)? TU_Prefix : TU_Complete;
   bool CacheCodeCompetionResults
     = options & CXTranslationUnit_CacheCompletionResults;
-  
+  bool SkipFunctionBodies = options & CXTranslationUnit_SkipFunctionBodies;
+
   // Configure the diagnostics.
   DiagnosticOptions DiagOpts;
   IntrusiveRefCntPtr<DiagnosticsEngine>
@@ -2587,6 +2590,7 @@
   }
   
   unsigned NumErrors = Diags->getClient()->getNumErrors();
+  OwningPtr<ASTUnit> ErrUnit;
   OwningPtr<ASTUnit> Unit(
     ASTUnit::LoadFromCommandLine(Args->size() ? &(*Args)[0] : 0 
                                  /* vector::data() not portable */,
@@ -2601,27 +2605,14 @@
                                  PrecompilePreamble,
                                  TUKind,
                                  CacheCodeCompetionResults,
-                                 /*AllowPCHWithCompilerErrors=*/true));
+                                 /*AllowPCHWithCompilerErrors=*/true,
+                                 SkipFunctionBodies,
+                                 &ErrUnit));
 
   if (NumErrors != Diags->getClient()->getNumErrors()) {
     // Make sure to check that 'Unit' is non-NULL.
-    if (CXXIdx->getDisplayDiagnostics() && Unit.get()) {
-      for (ASTUnit::stored_diag_iterator D = Unit->stored_diag_begin(), 
-                                      DEnd = Unit->stored_diag_end();
-           D != DEnd; ++D) {
-        CXStoredDiagnostic Diag(*D, Unit->getASTContext().getLangOpts());
-        CXString Msg = clang_formatDiagnostic(&Diag,
-                                    clang_defaultDiagnosticDisplayOptions());
-        fprintf(stderr, "%s\n", clang_getCString(Msg));
-        clang_disposeString(Msg);
-      }
-#ifdef LLVM_ON_WIN32
-      // On Windows, force a flush, since there may be multiple copies of
-      // stderr and stdout in the file system, all with different buffers
-      // but writing to the same device.
-      fflush(stderr);
-#endif
-    }
+    if (CXXIdx->getDisplayDiagnostics())
+      printDiagsToStderr(Unit ? Unit.get() : ErrUnit.get());
   }
 
   PTUI->result = MakeCXTranslationUnit(CXXIdx, Unit.take());
@@ -5535,6 +5526,8 @@
     *num_overridden = 0;
   if (!overridden || !num_overridden)
     return;
+  if (!clang_isDeclaration(cursor.kind))
+    return;
 
   SmallVector<CXCursor, 8> Overridden;
   cxcursor::getOverriddenCursors(cursor, Overridden);
@@ -5820,6 +5813,27 @@
 #endif
 }
 
+void cxindex::printDiagsToStderr(ASTUnit *Unit) {
+  if (!Unit)
+    return;
+
+  for (ASTUnit::stored_diag_iterator D = Unit->stored_diag_begin(), 
+                                  DEnd = Unit->stored_diag_end();
+       D != DEnd; ++D) {
+    CXStoredDiagnostic Diag(*D, Unit->getASTContext().getLangOpts());
+    CXString Msg = clang_formatDiagnostic(&Diag,
+                                clang_defaultDiagnosticDisplayOptions());
+    fprintf(stderr, "%s\n", clang_getCString(Msg));
+    clang_disposeString(Msg);
+  }
+#ifdef LLVM_ON_WIN32
+  // On Windows, force a flush, since there may be multiple copies of
+  // stderr and stdout in the file system, all with different buffers
+  // but writing to the same device.
+  fflush(stderr);
+#endif
+}
+
 extern "C" {
 
 CXString clang_getClangVersion() {

Modified: cfe/branches/tooling/tools/libclang/CIndexCodeCompletion.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/libclang/CIndexCodeCompletion.cpp?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/libclang/CIndexCodeCompletion.cpp (original)
+++ cfe/branches/tooling/tools/libclang/CIndexCodeCompletion.cpp Tue Apr 17 06:08:26 2012
@@ -264,7 +264,8 @@
     CachedCompletionAllocator;
   
   /// \brief Allocator used to store code completion results.
-  clang::CodeCompletionAllocator CodeCompletionAllocator;
+  IntrusiveRefCntPtr<clang::GlobalCodeCompletionAllocator>
+    CodeCompletionAllocator;
   
   /// \brief Context under which completion occurred.
   enum clang::CodeCompletionContext::Kind ContextKind;
@@ -300,6 +301,7 @@
     FileSystemOpts(FileSystemOpts),
     FileMgr(new FileManager(FileSystemOpts)),
     SourceMgr(new SourceManager(*Diag, *FileMgr)),
+    CodeCompletionAllocator(new clang::GlobalCodeCompletionAllocator),
     Contexts(CXCompletionContext_Unknown),
     ContainerKind(CXCursor_InvalidCode),
     ContainerUSR(createCXString("")),
@@ -503,13 +505,15 @@
 namespace {
   class CaptureCompletionResults : public CodeCompleteConsumer {
     AllocatedCXCodeCompleteResults &AllocatedResults;
+    CodeCompletionTUInfo CCTUInfo;
     SmallVector<CXCompletionResult, 16> StoredResults;
     CXTranslationUnit *TU;
   public:
     CaptureCompletionResults(AllocatedCXCodeCompleteResults &Results,
                              CXTranslationUnit *TranslationUnit)
       : CodeCompleteConsumer(true, false, true, false), 
-        AllocatedResults(Results), TU(TranslationUnit) { }
+        AllocatedResults(Results), CCTUInfo(Results.CodeCompletionAllocator),
+        TU(TranslationUnit) { }
     ~CaptureCompletionResults() { Finish(); }
     
     virtual void ProcessCodeCompleteResults(Sema &S, 
@@ -519,8 +523,8 @@
       StoredResults.reserve(StoredResults.size() + NumResults);
       for (unsigned I = 0; I != NumResults; ++I) {
         CodeCompletionString *StoredCompletion        
-          = Results[I].CreateCodeCompletionString(S, 
-                                      AllocatedResults.CodeCompletionAllocator);
+          = Results[I].CreateCodeCompletionString(S, getAllocator(),
+                                                  getCodeCompletionTUInfo());
         
         CXCompletionResult R;
         R.CursorKind = Results[I].CursorKind;
@@ -607,8 +611,8 @@
       StoredResults.reserve(StoredResults.size() + NumCandidates);
       for (unsigned I = 0; I != NumCandidates; ++I) {
         CodeCompletionString *StoredCompletion
-          = Candidates[I].CreateSignatureString(CurrentArg, S, 
-                                      AllocatedResults.CodeCompletionAllocator);
+          = Candidates[I].CreateSignatureString(CurrentArg, S, getAllocator(),
+                                                getCodeCompletionTUInfo());
         
         CXCompletionResult R;
         R.CursorKind = CXCursor_NotImplemented;
@@ -618,8 +622,10 @@
     }
     
     virtual CodeCompletionAllocator &getAllocator() { 
-      return AllocatedResults.CodeCompletionAllocator;
+      return *AllocatedResults.CodeCompletionAllocator;
     }
+
+    virtual CodeCompletionTUInfo &getCodeCompletionTUInfo() { return CCTUInfo; }
     
   private:
     void Finish() {

Modified: cfe/branches/tooling/tools/libclang/CIndexDiagnostic.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/libclang/CIndexDiagnostic.cpp?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/libclang/CIndexDiagnostic.cpp (original)
+++ cfe/branches/tooling/tools/libclang/CIndexDiagnostic.cpp Tue Apr 17 06:08:26 2012
@@ -72,6 +72,8 @@
   }
   
   unsigned getCategory() const { return 0; }
+  CXString getCategoryText() const { return createCXString(""); }
+
   unsigned getNumRanges() const { return 0; }
   CXSourceRange getRange(unsigned Range) const { return clang_getNullRange(); }
   unsigned getNumFixIts() const { return 0; }
@@ -324,7 +326,7 @@
         }
         
         if (Options & CXDiagnostic_DisplayCategoryName) {
-          CXString CategoryName = clang_getDiagnosticCategoryName(CategoryID);
+          CXString CategoryName = clang_getDiagnosticCategoryText(Diagnostic);
           if (NeedBracket)
             Out << " [";
           if (NeedComma)
@@ -336,7 +338,8 @@
         }
       }
     }
-    
+
+    (void) NeedComma; // Silence dead store warning.
     if (!NeedBracket)
       Out << "]";
   }
@@ -384,9 +387,16 @@
 }
   
 CXString clang_getDiagnosticCategoryName(unsigned Category) {
+  // Kept for backwards compatibility.
   return createCXString(DiagnosticIDs::getCategoryNameFromID(Category));
 }
   
+CXString clang_getDiagnosticCategoryText(CXDiagnostic Diag) {
+  if (CXDiagnosticImpl *D = static_cast<CXDiagnosticImpl *>(Diag))
+    return D->getCategoryText();
+  return createCXString("");
+}
+  
 unsigned clang_getDiagnosticNumRanges(CXDiagnostic Diag) {
   if (CXDiagnosticImpl *D = static_cast<CXDiagnosticImpl *>(Diag))
     return D->getNumRanges();

Modified: cfe/branches/tooling/tools/libclang/CIndexDiagnostic.h
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/libclang/CIndexDiagnostic.h?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/libclang/CIndexDiagnostic.h (original)
+++ cfe/branches/tooling/tools/libclang/CIndexDiagnostic.h Tue Apr 17 06:08:26 2012
@@ -73,7 +73,10 @@
   
   /// \brief Return the category of the diagnostic.
   virtual unsigned getCategory() const = 0;
-  
+
+  /// \brief Return the category string of the diagnostic.
+  virtual CXString getCategoryText() const = 0;
+
   /// \brief Return the number of source ranges for the diagnostic.
   virtual unsigned getNumRanges() const = 0;
   
@@ -132,6 +135,9 @@
   /// \brief Return the category of the diagnostic.
   virtual unsigned getCategory() const;
   
+  /// \brief Return the category string of the diagnostic.
+  virtual CXString getCategoryText() const;
+
   /// \brief Return the number of source ranges for the diagnostic.
   virtual unsigned getNumRanges() const;
   

Modified: cfe/branches/tooling/tools/libclang/CIndexer.h
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/libclang/CIndexer.h?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/libclang/CIndexer.h (original)
+++ cfe/branches/tooling/tools/libclang/CIndexer.h Tue Apr 17 06:08:26 2012
@@ -25,6 +25,7 @@
 }
 
 namespace clang {
+  class ASTUnit;
 
 class CIndexer {
   bool OnlyLocalDecls;
@@ -94,6 +95,10 @@
 
   /// \brief Print libclang's resource usage to standard error.
   void PrintLibclangResourceUsage(CXTranslationUnit TU);
+
+  namespace cxindex {
+    void printDiagsToStderr(ASTUnit *Unit);
+  }
 }
 
 #endif

Modified: cfe/branches/tooling/tools/libclang/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/libclang/CMakeLists.txt?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/libclang/CMakeLists.txt (original)
+++ cfe/branches/tooling/tools/libclang/CMakeLists.txt Tue Apr 17 06:08:26 2012
@@ -4,7 +4,6 @@
   clangFrontend
   clangDriver
   clangSerialization
-  clangIndex
   clangSema
   clangEdit
   clangAST

Modified: cfe/branches/tooling/tools/libclang/CXCursor.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/libclang/CXCursor.cpp?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/libclang/CXCursor.cpp (original)
+++ cfe/branches/tooling/tools/libclang/CXCursor.cpp Tue Apr 17 06:08:26 2012
@@ -786,14 +786,11 @@
   return static_cast<CXTranslationUnit>(Cursor.data[2]);
 }
 
-static void CollectOverriddenMethods(CXTranslationUnit TU,
-                                     DeclContext *Ctx, 
+static void CollectOverriddenMethodsRecurse(CXTranslationUnit TU,
+                                     ObjCContainerDecl *Container, 
                                      ObjCMethodDecl *Method,
-                                     SmallVectorImpl<CXCursor> &Methods) {
-  if (!Ctx)
-    return;
-
-  ObjCContainerDecl *Container = dyn_cast<ObjCContainerDecl>(Ctx);
+                                     SmallVectorImpl<CXCursor> &Methods,
+                                     bool MovedToSuper) {
   if (!Container)
     return;
 
@@ -801,10 +798,23 @@
   // category is not "overriden" since it is considered as the "same" method
   // (same USR) as the one from the interface.
   if (ObjCCategoryDecl *Category = dyn_cast<ObjCCategoryDecl>(Container)) {
+    // Check whether we have a matching method at this category but only if we
+    // are at the super class level.
+    if (MovedToSuper)
+      if (ObjCMethodDecl *
+            Overridden = Container->getMethod(Method->getSelector(),
+                                              Method->isInstanceMethod()))
+        if (Method != Overridden) {
+          // We found an override at this category; there is no need to look
+          // into its protocols.
+          Methods.push_back(MakeCXCursor(Overridden, TU));
+          return;
+        }
+
     for (ObjCCategoryDecl::protocol_iterator P = Category->protocol_begin(),
                                           PEnd = Category->protocol_end();
          P != PEnd; ++P)
-      CollectOverriddenMethods(TU, *P, Method, Methods);
+      CollectOverriddenMethodsRecurse(TU, *P, Method, Methods, MovedToSuper);
     return;
   }
 
@@ -822,29 +832,37 @@
     for (ObjCProtocolDecl::protocol_iterator P = Protocol->protocol_begin(),
                                           PEnd = Protocol->protocol_end();
          P != PEnd; ++P)
-      CollectOverriddenMethods(TU, *P, Method, Methods);
+      CollectOverriddenMethodsRecurse(TU, *P, Method, Methods, MovedToSuper);
   }
 
   if (ObjCInterfaceDecl *Interface = dyn_cast<ObjCInterfaceDecl>(Container)) {
     for (ObjCInterfaceDecl::protocol_iterator P = Interface->protocol_begin(),
                                            PEnd = Interface->protocol_end();
          P != PEnd; ++P)
-      CollectOverriddenMethods(TU, *P, Method, Methods);
+      CollectOverriddenMethodsRecurse(TU, *P, Method, Methods, MovedToSuper);
 
     for (ObjCCategoryDecl *Category = Interface->getCategoryList();
          Category; Category = Category->getNextClassCategory())
-      CollectOverriddenMethods(TU, Category, Method, Methods);
+      CollectOverriddenMethodsRecurse(TU, Category, Method, Methods,
+                                      MovedToSuper);
 
     if (ObjCInterfaceDecl *Super = Interface->getSuperClass())
-      return CollectOverriddenMethods(TU, Super, Method, Methods);
+      return CollectOverriddenMethodsRecurse(TU, Super, Method, Methods,
+                                             /*MovedToSuper=*/true);
   }
 }
 
+static inline void CollectOverriddenMethods(CXTranslationUnit TU,
+                                           ObjCContainerDecl *Container, 
+                                           ObjCMethodDecl *Method,
+                                           SmallVectorImpl<CXCursor> &Methods) {
+  CollectOverriddenMethodsRecurse(TU, Container, Method, Methods,
+                                  /*MovedToSuper=*/false);
+}
+
 void cxcursor::getOverriddenCursors(CXCursor cursor,
                                     SmallVectorImpl<CXCursor> &overridden) { 
-  if (!clang_isDeclaration(cursor.kind))
-    return;
-
+  assert(clang_isDeclaration(cursor.kind));
   Decl *D = getCursorDecl(cursor);
   if (!D)
     return;
@@ -893,7 +911,9 @@
     CollectOverriddenMethods(TU, ID, Method, overridden);
 
   } else {
-    CollectOverriddenMethods(TU, Method->getDeclContext(), Method, overridden);
+    CollectOverriddenMethods(TU,
+                  dyn_cast_or_null<ObjCContainerDecl>(Method->getDeclContext()),
+                  Method, overridden);
   }
 }
 
@@ -1004,6 +1024,35 @@
   return getCursorTU(cursor);
 }
 
+int clang_Cursor_getNumArguments(CXCursor C) {
+  if (clang_isDeclaration(C.kind)) {
+    Decl *D = cxcursor::getCursorDecl(C);
+    if (const ObjCMethodDecl *MD = dyn_cast_or_null<ObjCMethodDecl>(D))
+      return MD->param_size();
+    if (const FunctionDecl *FD = dyn_cast_or_null<FunctionDecl>(D))
+      return FD->param_size();
+  }
+
+  return -1;
+}
+
+CXCursor clang_Cursor_getArgument(CXCursor C, unsigned i) {
+  if (clang_isDeclaration(C.kind)) {
+    Decl *D = cxcursor::getCursorDecl(C);
+    if (ObjCMethodDecl *MD = dyn_cast_or_null<ObjCMethodDecl>(D)) {
+      if (i < MD->param_size())
+        return cxcursor::MakeCXCursor(MD->param_begin()[i],
+                                      cxcursor::getCursorTU(C));
+    } else if (FunctionDecl *FD = dyn_cast_or_null<FunctionDecl>(D)) {
+      if (i < FD->param_size())
+        return cxcursor::MakeCXCursor(FD->param_begin()[i],
+                                      cxcursor::getCursorTU(C));
+    }
+  }
+
+  return clang_getNullCursor();
+}
+
 } // end: extern "C"
 
 //===----------------------------------------------------------------------===//
@@ -1076,13 +1125,12 @@
     Decl *decl = getCursorDecl(cursor);
     if (NamedDecl *namedDecl = dyn_cast_or_null<NamedDecl>(decl)) {
       ASTUnit *unit = getCursorASTUnit(cursor);
-      CodeCompletionAllocator *Allocator
-        = unit->getCursorCompletionAllocator().getPtr();
       CodeCompletionResult Result(namedDecl);
       CodeCompletionString *String
         = Result.CreateCodeCompletionString(unit->getASTContext(),
                                             unit->getPreprocessor(),
-                                            *Allocator);
+                                 unit->getCodeCompletionTUInfo().getAllocator(),
+                                 unit->getCodeCompletionTUInfo());
       return String;
     }
   }
@@ -1090,13 +1138,12 @@
     MacroDefinition *definition = getCursorMacroDefinition(cursor);
     const IdentifierInfo *MacroInfo = definition->getName();
     ASTUnit *unit = getCursorASTUnit(cursor);
-    CodeCompletionAllocator *Allocator
-      = unit->getCursorCompletionAllocator().getPtr();
     CodeCompletionResult Result(const_cast<IdentifierInfo *>(MacroInfo));
     CodeCompletionString *String
       = Result.CreateCodeCompletionString(unit->getASTContext(),
                                           unit->getPreprocessor(),
-                                          *Allocator);
+                                 unit->getCodeCompletionTUInfo().getAllocator(),
+                                 unit->getCodeCompletionTUInfo());
     return String;
   }
   return NULL;

Modified: cfe/branches/tooling/tools/libclang/CXLoadedDiagnostic.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/libclang/CXLoadedDiagnostic.cpp?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/libclang/CXLoadedDiagnostic.cpp (original)
+++ cfe/branches/tooling/tools/libclang/CXLoadedDiagnostic.cpp Tue Apr 17 06:08:26 2012
@@ -119,6 +119,10 @@
   return category;
 }
 
+CXString CXLoadedDiagnostic::getCategoryText() const {
+  return cxstring::createCXString(CategoryText);
+}
+
 unsigned CXLoadedDiagnostic::getNumRanges() const {
   return Ranges.size();
 }
@@ -650,6 +654,7 @@
         D->category = Record[offset++];
         unsigned diagFlag = Record[offset++];
         D->DiagOption = diagFlag ? TopDiags.WarningFlags[diagFlag] : "";
+        D->CategoryText = D->category ? TopDiags.Categories[D->category] : "";
         D->Spelling = TopDiags.makeString(BlobStart, BlobLen);
         continue;
       }

Modified: cfe/branches/tooling/tools/libclang/CXLoadedDiagnostic.h
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/libclang/CXLoadedDiagnostic.h?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/libclang/CXLoadedDiagnostic.h (original)
+++ cfe/branches/tooling/tools/libclang/CXLoadedDiagnostic.h Tue Apr 17 06:08:26 2012
@@ -43,6 +43,9 @@
   /// \brief Return the category of the diagnostic.
   virtual unsigned getCategory() const;
   
+  /// \brief Return the category string of the diagnostic.
+  virtual CXString getCategoryText() const;
+  
   /// \brief Return the number of source ranges for the diagnostic.
   virtual unsigned getNumRanges() const;
   
@@ -82,6 +85,7 @@
   std::vector<std::pair<CXSourceRange, CXString> > FixIts;
   llvm::StringRef Spelling;
   llvm::StringRef DiagOption;
+  llvm::StringRef CategoryText;
   unsigned severity;
   unsigned category;
 };

Modified: cfe/branches/tooling/tools/libclang/CXStoredDiagnostic.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/libclang/CXStoredDiagnostic.cpp?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/libclang/CXStoredDiagnostic.cpp (original)
+++ cfe/branches/tooling/tools/libclang/CXStoredDiagnostic.cpp Tue Apr 17 06:08:26 2012
@@ -79,6 +79,11 @@
   return DiagnosticIDs::getCategoryNumberForDiag(Diag.getID());
 }
 
+CXString CXStoredDiagnostic::getCategoryText() const {
+  unsigned catID = DiagnosticIDs::getCategoryNumberForDiag(Diag.getID());
+  return createCXString(DiagnosticIDs::getCategoryNameFromID(catID));
+}
+
 unsigned CXStoredDiagnostic::getNumRanges() const {
   if (Diag.getLocation().isInvalid())
     return 0;

Modified: cfe/branches/tooling/tools/libclang/CXType.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/libclang/CXType.cpp?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/libclang/CXType.cpp (original)
+++ cfe/branches/tooling/tools/libclang/CXType.cpp Tue Apr 17 06:08:26 2012
@@ -455,10 +455,10 @@
   return CXCallingConv_Invalid;
 }
 
-unsigned clang_getNumArgTypes(CXType X) {
+int clang_getNumArgTypes(CXType X) {
   QualType T = GetQualType(X);
   if (T.isNull())
-    return UINT_MAX;
+    return -1;
   
   if (const FunctionProtoType *FD = T->getAs<FunctionProtoType>()) {
     return FD->getNumArgs();
@@ -468,7 +468,7 @@
     return 0;
   }
   
-  return UINT_MAX;
+  return -1;
 }
 
 CXType clang_getArgType(CXType X, unsigned i) {

Modified: cfe/branches/tooling/tools/libclang/Indexing.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/libclang/Indexing.cpp?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/libclang/Indexing.cpp (original)
+++ cfe/branches/tooling/tools/libclang/Indexing.cpp Tue Apr 17 06:08:26 2012
@@ -388,7 +388,8 @@
     }
   }
 
-  Unit = ASTUnit::LoadFromCompilerInvocationAction(CInvok.getPtr(), Diags,
+  DiagnosticErrorTrap DiagTrap(*Diags);
+  bool Success = ASTUnit::LoadFromCompilerInvocationAction(CInvok.getPtr(), Diags,
                                                        IndexAction.get(),
                                                        Unit,
                                                        Persistent,
@@ -397,7 +398,10 @@
                                                     /*CaptureDiagnostics=*/true,
                                                        PrecompilePreamble,
                                                     CacheCodeCompletionResults);
-  if (!Unit)
+  if (DiagTrap.hasErrorOccurred() && CXXIdx->getDisplayDiagnostics())
+    printDiagsToStderr(Unit);
+
+  if (!Success)
     return;
 
   if (out_TU)

Modified: cfe/branches/tooling/tools/libclang/libclang.exports
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/libclang/libclang.exports?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/libclang/libclang.exports (original)
+++ cfe/branches/tooling/tools/libclang/libclang.exports Tue Apr 17 06:08:26 2012
@@ -4,9 +4,11 @@
 clang_CXIndex_setGlobalOptions
 clang_CXXMethod_isStatic
 clang_CXXMethod_isVirtual
+clang_Cursor_getArgument
+clang_Cursor_getNumArguments
+clang_Cursor_getObjCSelectorIndex
 clang_Cursor_getSpellingNameRange
 clang_Cursor_getTranslationUnit
-clang_Cursor_getObjCSelectorIndex
 clang_Cursor_isNull
 clang_IndexAction_create
 clang_IndexAction_dispose
@@ -95,6 +97,7 @@
 clang_getDiagnostic
 clang_getDiagnosticCategory
 clang_getDiagnosticCategoryName
+clang_getDiagnosticCategoryText
 clang_getDiagnosticFixIt
 clang_getDiagnosticInSet
 clang_getDiagnosticLocation

Modified: cfe/branches/tooling/tools/remove-cstr-calls/RemoveCStrCalls.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/tools/remove-cstr-calls/RemoveCStrCalls.cpp?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/tools/remove-cstr-calls/RemoveCStrCalls.cpp (original)
+++ cfe/branches/tooling/tools/remove-cstr-calls/RemoveCStrCalls.cpp Tue Apr 17 06:08:26 2012
@@ -39,10 +39,12 @@
 #include "clang/Basic/SourceManager.h"
 #include "clang/Frontend/FrontendActions.h"
 #include "clang/Lex/Lexer.h"
+#include "clang/Tooling/CompilationDatabase.h"
 #include "clang/Tooling/Refactoring.h"
 #include "clang/Tooling/Tooling.h"
 #include "llvm/ADT/OwningPtr.h"
 #include "llvm/ADT/Twine.h"
+#include "llvm/Support/CommandLine.h"
 #include "llvm/Support/MemoryBuffer.h"
 #include "llvm/Support/Path.h"
 #include "llvm/Support/raw_ostream.h"
@@ -50,8 +52,10 @@
 
 using namespace clang;
 using namespace clang::ast_matchers;
-using clang::tooling::NewFrontendActionFactory;
+using namespace llvm;
+using clang::tooling::newFrontendActionFactory;
 using clang::tooling::Replacement;
+using clang::tooling::CompilationDatabase;
 
 // FIXME: Pull out helper methods in here into more fitting places.
 
@@ -163,8 +167,23 @@
     "::std::basic_string<char, std::char_traits<char>, std::allocator<char> >"
     "::c_str";
 
+cl::opt<std::string> BuildPath(
+  cl::Positional,
+  cl::desc("<build-path>"));
+
+cl::list<std::string> SourcePaths(
+  cl::Positional,
+  cl::desc("<source0> [... <sourceN>]"),
+  cl::OneOrMore);
+
 int main(int argc, char **argv) {
-  tooling::RefactoringTool Tool(argc, argv);
+  cl::ParseCommandLineOptions(argc, argv);
+  std::string ErrorMessage;
+  llvm::OwningPtr<CompilationDatabase> Compilations(
+    CompilationDatabase::loadFromDirectory(BuildPath, ErrorMessage));
+  if (!Compilations)
+    llvm::report_fatal_error(ErrorMessage);
+  tooling::RefactoringTool Tool(*Compilations, SourcePaths);
   ast_matchers::MatchFinder Finder;
   Finder.addMatcher(
       ConstructorCall(
@@ -208,6 +227,6 @@
                   Callee(Method(HasName(StringCStrMethod))),
                   On(Id("arg", Expression())))))),
       new FixCStrCall(&Tool.GetReplacements()));
-  return Tool.Run(NewFrontendActionFactory(&Finder));
+  return Tool.Run(newFrontendActionFactory(&Finder));
 }
 

Modified: cfe/branches/tooling/unittests/ASTMatchers/ASTMatchersTest.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/unittests/ASTMatchers/ASTMatchersTest.cpp?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/unittests/ASTMatchers/ASTMatchersTest.cpp (original)
+++ cfe/branches/tooling/unittests/ASTMatchers/ASTMatchersTest.cpp Tue Apr 17 06:08:26 2012
@@ -15,7 +15,7 @@
 namespace clang {
 namespace ast_matchers {
 
-using clang::tooling::RunSyntaxOnlyToolOnCode;
+using clang::tooling::runToolOnCode;
 
 class BoundNodesCallback {
 public:
@@ -51,7 +51,7 @@
   bool Found = false;
   MatchFinder Finder;
   Finder.addMatcher(AMatcher, new VerifyMatch(0, &Found));
-  if (!RunSyntaxOnlyToolOnCode(Finder.newFrontendAction(), Code)) {
+  if (!runToolOnCode(Finder.newFrontendAction(), Code)) {
     return testing::AssertionFailure() << "Parsing error in \"" << Code << "\"";
   }
   if (!Found && ExpectMatch) {
@@ -85,7 +85,7 @@
   MatchFinder Finder;
   Finder.addMatcher(
       AMatcher, new VerifyMatch(FindResultVerifier, &VerifiedResult));
-  if (!RunSyntaxOnlyToolOnCode(Finder.newFrontendAction(), Code)) {
+  if (!runToolOnCode(Finder.newFrontendAction(), Code)) {
     return testing::AssertionFailure() << "Parsing error in \"" << Code << "\"";
   }
   if (!VerifiedResult && ExpectResult) {

Modified: cfe/branches/tooling/unittests/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/unittests/CMakeLists.txt?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/unittests/CMakeLists.txt (original)
+++ cfe/branches/tooling/unittests/CMakeLists.txt Tue Apr 17 06:08:26 2012
@@ -72,6 +72,7 @@
  )
 
 add_clang_unittest(Tooling
+  Tooling/CompilationDatabaseTest.cpp
   Tooling/ToolingTest.cpp
   Tooling/RefactoringTest.cpp
   USED_LIBS gtest gtest_main clangTooling

Modified: cfe/branches/tooling/unittests/Frontend/Makefile
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/unittests/Frontend/Makefile?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/unittests/Frontend/Makefile (original)
+++ cfe/branches/tooling/unittests/Frontend/Makefile Tue Apr 17 06:08:26 2012
@@ -13,7 +13,7 @@
 USEDLIBS = clangFrontendTool.a clangFrontend.a clangDriver.a \
            clangSerialization.a clangCodeGen.a clangParse.a clangSema.a \
            clangStaticAnalyzerCheckers.a clangStaticAnalyzerCore.a \
-           clangIndex.a clangARCMigrate.a clangRewrite.a clangEdit.a \
+           clangARCMigrate.a clangRewrite.a clangEdit.a \
            clangAnalysis.a clangAST.a clangLex.a clangBasic.a
 
 include $(CLANG_LEVEL)/unittests/Makefile

Propchange: cfe/branches/tooling/unittests/Tooling/CompilationDatabaseTest.cpp
------------------------------------------------------------------------------
    svn:eol-style = LF

Propchange: cfe/branches/tooling/unittests/Tooling/CompilationDatabaseTest.cpp
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Tue Apr 17 06:08:26 2012
@@ -0,0 +1,2 @@
+/cfe/branches/type-system-rewrite/unittests/Tooling/CompilationDatabaseTest.cpp:134693-134817
+/cfe/trunk/test/SemaTemplate/unittests/Tooling/CompilationDatabaseTest.cpp:126920

Modified: cfe/branches/tooling/unittests/Tooling/RefactoringTest.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/unittests/Tooling/RefactoringTest.cpp?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/unittests/Tooling/RefactoringTest.cpp (original)
+++ cfe/branches/tooling/unittests/Tooling/RefactoringTest.cpp Tue Apr 17 06:08:26 2012
@@ -252,7 +252,7 @@
 class TestVisitor : public clang::RecursiveASTVisitor<T> {
 public:
   bool runOver(StringRef Code) {
-    return RunSyntaxOnlyToolOnCode(new TestAction(this), Code);
+    return runToolOnCode(new TestAction(this), Code);
   }
 
 protected:

Propchange: cfe/branches/tooling/unittests/Tooling/ToolingTest.cpp
------------------------------------------------------------------------------
    svn:eol-style = LF

Propchange: cfe/branches/tooling/unittests/Tooling/ToolingTest.cpp
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Tue Apr 17 06:08:26 2012
@@ -0,0 +1,2 @@
+/cfe/branches/type-system-rewrite/unittests/Tooling/ToolingTest.cpp:134693-134817
+/cfe/trunk/test/SemaTemplate/unittests/Tooling/ToolingTest.cpp:126920

Modified: cfe/branches/tooling/www/cxx_status.html
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/tooling/www/cxx_status.html?rev=154919&r1=154918&r2=154919&view=diff
==============================================================================
--- cfe/branches/tooling/www/cxx_status.html (original)
+++ cfe/branches/tooling/www/cxx_status.html Tue Apr 17 06:08:26 2012
@@ -120,6 +120,11 @@
       <td class="full" align="center">Clang 2.9</td>
     </tr>
     <tr>
+      <td>    Incomplete return types</td>
+      <td><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2011/n3276.pdf">N3276</a></td>
+      <td class="svn" align="center">SVN</td>
+    </tr>
+    <tr>
       <td>Right angle brackets</td>
       <td><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2005/n1757.html">N1757</a></td>
       <td class="full" align="center">Clang 2.9</td>
@@ -297,7 +302,7 @@
     <tr>
       <td>Atomic operations</td>
       <td><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2007/n2427.html">N2427</a></td>
-      <td class="none" align="center">No</td>
+      <td class="svn" align="center">SVN</td>
     </tr>
     <tr>
       <td>Strong Compare and Exchange</td>
@@ -307,7 +312,7 @@
     <tr>
       <td>Bidirectional Fences</td>
       <td><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2008/n2752.htm">N2752</a></td>
-      <td class="none" align="center">No</td>
+      <td class="svn" align="center">SVN</td>
     </tr>
 
     <tr>
@@ -328,12 +333,12 @@
     <tr>
       <td>Abandoning a process and at_quick_exit</td>
       <td><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2007/n2440.htm">N2440</a></td>
-      <td class="none" align="center">No</td>
+      <td class="na" align="center">N/A</td>
     </tr>
     <tr>
       <td>Allow atomics use in signal handlers</td>
       <td><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2008/n2547.htm">N2547</a></td>
-      <td class="none" align="center">No</td>
+      <td class="svn" align="center">SVN</td>
     </tr>
     <tr>
       <td>Thread-local storage</td>





More information about the llvm-branch-commits mailing list