[cfe-commits] r60731 - /cfe/trunk/test/Analysis/misc-ps.m
Ted Kremenek
kremenek at apple.com
Mon Dec 8 16:14:48 PST 2008
Author: kremenek
Date: Mon Dec 8 18:14:48 2008
New Revision: 60731
URL: http://llvm.org/viewvc/llvm-project?rev=60731&view=rev
Log:
Add zero-sized VLA check test case.
Modified:
cfe/trunk/test/Analysis/misc-ps.m
Modified: cfe/trunk/test/Analysis/misc-ps.m
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Analysis/misc-ps.m?rev=60731&r1=60730&r2=60731&view=diff
==============================================================================
--- cfe/trunk/test/Analysis/misc-ps.m (original)
+++ cfe/trunk/test/Analysis/misc-ps.m Mon Dec 8 18:14:48 2008
@@ -74,4 +74,11 @@
return __extension__ (__m128i)(__v2di){ __q0, __q1 };
}
+// Zero-sized VLAs.
+void check_zero_sized_VLA(int x) {
+ if (x)
+ return;
+
+ int vla[x]; // expected-warning{{VLAs with zero-size are undefined}}
+}
More information about the cfe-commits
mailing list