https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68266
Bug ID: 68266 Summary: pointers to arrays of excessive size not diagnosed Product: gcc Version: 6.0 Status: UNCONFIRMED Severity: minor Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: msebor at gcc dot gnu.org Target Milestone: --- In C mode, GCC issues an error for pointers to arrays of excessive size such as the one in the program below. However, in C++ mode, it fails to diagnose the same invalid constructs. $ cat u.cpp && /build/gcc-trunk-svn/gcc/xg++ -B /build/gcc-trunk-svn/gcc -S -Wall -Wextra -Wpedantic -o /dev/tty u.cpp typedef __typeof__ (sizeof 0) size_t; typedef int (*A)[__SIZE_MAX__]; .file "u.cpp" .ident "GCC: (GNU) 6.0.0 20151108 (experimental)" .section .note.GNU-stack,"",@progbits $