Mercurial > hg > CbC > CbC_gcc
view gcc/testsuite/gcc.dg/Wlarger-than3.c @ 131:84e7813d76e9
gcc-8.2
author | mir3636 |
---|---|
date | Thu, 25 Oct 2018 07:37:49 +0900 |
parents | |
children | 1830386684a0 |
line wrap: on
line source
/* Exercise -Wlarger-than= with a byte-size suffix. { dg-do compile } { dg-options "-Wlarger-than=1MiB" } */ #define MB (1000 * 1000) /* MegaByte */ #define MiB (1024 * 1024) /* MebiByte */ char megabyte[MB]; char membibyte[MiB]; char megabyte_plus_1[MB + 1]; char membibyte_plus_1[MiB + 1]; /* { dg-warning "size of .membibyte_plus_1. 1048577 bytes exceeds maximum object size 1048576" } */