* c-c++-common/pr50459.c: Move cdtor tests to a separate testcase.
authormpolacek <mpolacek@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 13 May 2014 17:37:40 +0000 (17:37 +0000)
committermpolacek <mpolacek@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 13 May 2014 17:37:40 +0000 (17:37 +0000)
* c-c++-common/pr50459-2.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@210390 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/testsuite/ChangeLog
gcc/testsuite/c-c++-common/pr50459-2.c [new file with mode: 0644]
gcc/testsuite/c-c++-common/pr50459.c

index 0ae3424..98a6505 100644 (file)
@@ -1,3 +1,8 @@
+2014-05-13  Marek Polacek  <polacek@redhat.com>
+
+       * c-c++-common/pr50459.c: Move cdtor tests to a separate testcase.
+       * c-c++-common/pr50459-2.c: New test.
+
 2014-05-13  Paolo Carlini  <paolo.carlini@oracle.com>
 
        PR c++/54310
diff --git a/gcc/testsuite/c-c++-common/pr50459-2.c b/gcc/testsuite/c-c++-common/pr50459-2.c
new file mode 100644 (file)
index 0000000..0e8fec3
--- /dev/null
@@ -0,0 +1,7 @@
+/* PR c/50459 */
+/* { dg-do compile { target init_priority } } */
+/* { dg-options "-Wall -Wextra" } */
+
+enum { A = 128, B = 1 };
+void fn3 (void) __attribute__((constructor (A)));
+void fn4 (void) __attribute__((destructor (A)));
index f837b63..8d75228 100644 (file)
@@ -5,8 +5,6 @@
 enum { A = 128, B = 1 };
 void *fn1 (void) __attribute__((assume_aligned (A)));
 void *fn2 (void) __attribute__((assume_aligned (A, 4)));
-void fn3 (void) __attribute__((constructor (A)));
-void fn4 (void) __attribute__((destructor (A)));
 void *fn5 (int) __attribute__((alloc_size (B)));
 void *fn6 (int) __attribute__((alloc_align (B)));
 void fn7 (const char *, ...) __attribute__ ((sentinel (B)));