r196737 - Fix three tests that weren't checking anything
Alp Toker
alp at nuanti.com
Sun Dec 8 14:22:32 PST 2013
Author: alp
Date: Sun Dec 8 16:22:31 2013
New Revision: 196737
URL: http://llvm.org/viewvc/llvm-project?rev=196737&view=rev
Log:
Fix three tests that weren't checking anything
Add -verify and update the test directives to match current expectations.
Also add a FIXME to an ObjC test that has expected-* directives but no -verify.
Modified:
cfe/trunk/test/Sema/2009-03-09-WeakDeclarations-1.c
cfe/trunk/test/Sema/2009-04-22-UnknownSize.c
cfe/trunk/test/Sema/2009-07-17-VoidParameter.c
cfe/trunk/test/SemaObjC/selector-overload.m
Modified: cfe/trunk/test/Sema/2009-03-09-WeakDeclarations-1.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Sema/2009-03-09-WeakDeclarations-1.c?rev=196737&r1=196736&r2=196737&view=diff
==============================================================================
--- cfe/trunk/test/Sema/2009-03-09-WeakDeclarations-1.c (original)
+++ cfe/trunk/test/Sema/2009-03-09-WeakDeclarations-1.c Sun Dec 8 16:22:31 2013
@@ -1,12 +1,12 @@
-// RUN: %clang_cc1 %s -triple i686-apple-darwin
+// RUN: %clang_cc1 -verify %s -triple i686-apple-darwin
// Insist upon warnings for inappropriate weak attributes.
// O.K.
extern int ext_weak_import __attribute__ ((__weak_import__));
// These are inappropriate, and should generate warnings:
-int decl_weak_import __attribute__ ((__weak_import__)); // expected-warning {'weak_import' attribute cannot be specified on a definition}
-int decl_initialized_weak_import __attribute__ ((__weak_import__)) = 13; // expected-warning {'weak_import' attribute cannot be specified on a definition}
+int decl_weak_import __attribute__ ((__weak_import__)); // expected-warning {{'weak_import' attribute cannot be specified on a definition}}
+int decl_initialized_weak_import __attribute__ ((__weak_import__)) = 13; // expected-warning {{'weak_import' attribute cannot be specified on a definition}}
// O.K.
extern int ext_f(void) __attribute__ ((__weak_import__));
Modified: cfe/trunk/test/Sema/2009-04-22-UnknownSize.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Sema/2009-04-22-UnknownSize.c?rev=196737&r1=196736&r2=196737&view=diff
==============================================================================
--- cfe/trunk/test/Sema/2009-04-22-UnknownSize.c (original)
+++ cfe/trunk/test/Sema/2009-04-22-UnknownSize.c Sun Dec 8 16:22:31 2013
@@ -1,4 +1,4 @@
-// RUN: not %clang_cc1 %s -emit-llvm -o -
+// RUN: not %clang_cc1 -fsyntax-only -verify %s
// PR2958
static struct foo s; // expected-error { tentative definition has type 'struct foo' that is never completed }
struct foo *p = &s;
Modified: cfe/trunk/test/Sema/2009-07-17-VoidParameter.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Sema/2009-07-17-VoidParameter.c?rev=196737&r1=196736&r2=196737&view=diff
==============================================================================
--- cfe/trunk/test/Sema/2009-07-17-VoidParameter.c (original)
+++ cfe/trunk/test/Sema/2009-07-17-VoidParameter.c Sun Dec 8 16:22:31 2013
@@ -1,4 +1,4 @@
-// RUN: not %clang_cc1 -emit-llvm %s -o -
+// RUN: %clang_cc1 -verify -fsyntax-only %s
// PR4214
typedef void vt;
-void (*func_ptr)(vt my_vt); // expected-error {argument may not have 'void' type}
+void (*func_ptr)(vt my_vt); // expected-error {{argument may not have 'void' type}}
Modified: cfe/trunk/test/SemaObjC/selector-overload.m
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/SemaObjC/selector-overload.m?rev=196737&r1=196736&r2=196737&view=diff
==============================================================================
--- cfe/trunk/test/SemaObjC/selector-overload.m (original)
+++ cfe/trunk/test/SemaObjC/selector-overload.m Sun Dec 8 16:22:31 2013
@@ -1,4 +1,5 @@
// RUN: %clang_cc1 %s -fsyntax-only
+// FIXME: This test needs needs to be run with -verify
@interface NSObject
+ alloc;
More information about the cfe-commits
mailing list