]> granicus.if.org Git - clang/commitdiff
Move test case to a more appropriate file.
authorZhongxing Xu <xuzhongxing@gmail.com>
Tue, 5 Jan 2010 11:49:21 +0000 (11:49 +0000)
committerZhongxing Xu <xuzhongxing@gmail.com>
Tue, 5 Jan 2010 11:49:21 +0000 (11:49 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92725 91177308-0d34-0410-b5e6-96231b3b80d8

test/Analysis/casts.c
test/Analysis/misc-ps.m

index 947f63ef48b63ab6e8a2e9ca68caf03ccc4fc297..96c0226a0053c5f8e50bff244d83b1ba40b3d746 100644 (file)
@@ -45,3 +45,13 @@ void f2(const char *str) {
  if(!cl)
     cl = 'a';
 }
+
+// Test cast VariableSizeArray to pointer does not crash.
+void *memcpy(void *, void const *, unsigned long);
+typedef unsigned char Byte;
+void doit(char *data, int len) {
+    if (len) {
+        Byte buf[len];
+        memcpy(buf, data, len);
+    }
+}
index 2466dbe82e42d35743e43669fb900e1c846221e0..53b9b6f4fa67ad24091bc4a681a5a906c31fba71 100644 (file)
@@ -793,12 +793,3 @@ void test_bad_msg(TestBadArg *p) {
   [p testBadArg:y]; // expected-warning{{Pass-by-value argument in message expression is undefined}}
 }
 
-// Test cast VariableSizeArray to pointer does not crash.
-void *memcpy(void *, void const *, unsigned long);
-typedef unsigned char Byte;
-void doit(char *data, int len) {
-    if (len) {
-        Byte buf[len];
-        memcpy(buf, data, len);
-    }
-}