https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85783
--- Comment #2 from Paul Smith <psmith at gnu dot org> --- > Did you try: -Wno-alloc-size-larger-than ? Yes. cc1plus: error: unrecognized command line option '-Wno-alloc-size-larger-than' > Also in your code, numberFields is a signed int and then casted to size_t. > On LP64 targets (or rather sizeof(size_t) != sizeof(int)), then value is sign > extended. I'm not suggesting the code is well-written. Just that it shouldn't throw a warning. In any event, if I change numberFields to "unsigned int" I still get the same warning.