constexpr-52672.C (ul_ptr): Use SIZE_TYPE instead of hard-coded 'unsigned long'.

* g++.dg/cpp0x/constexpr-52672.C (ul_ptr): Use SIZE_TYPE instead of
        hard-coded 'unsigned long'.

From-SVN: r189056
This commit is contained in:
Kai Tietz 2012-06-28 22:29:20 +02:00 committed by Kai Tietz
parent 9965157413
commit 0ff7968cc0
2 changed files with 6 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2012-06-28 Kai Tietz <ktietz@redhat.com>
* g++.dg/cpp0x/constexpr-52672.C (ul_ptr): Use SIZE_TYPE instead of
hard-coded 'unsigned long'.
2012-06-28 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/51581

View File

@ -2,7 +2,7 @@
// { dg-do compile }
// { dg-options "-std=c++11" }
typedef unsigned long * ul_ptr;
__extension__ typedef __SIZE_TYPE__ * ul_ptr;
constexpr unsigned long a = *((ul_ptr)0x0); // { dg-error "" }
constexpr unsigned long b = *((ul_ptr)(*((ul_ptr)0x0))); // { dg-error "" }
constexpr unsigned long c = *((ul_ptr)*((ul_ptr)(*((ul_ptr)0x0)))); // { dg-error "" }