Sign in
gnu
/
gcc
/
ab810952eb7c061e37054ddd1dfe0aa033365131
/
.
/
gcc
/
testsuite
/
g++.dg
/
other
/
new-size-type.C
blob: 3411641e041fe17b54234566bd503cce15916bc4 [
file
] [
log
] [
blame
]
// Contributed by Dodji Seketeli <dodji@redhat.com>
// Origin: PR c++/36741
#include
<stddef.h>
const
char
*
foo
()
{
return
new
char
[~
static_cast
<size_t>
(
0
)];
// { dg-error "21:exceeds maximum object size" }
}