I recently fixed a bug that was the result of something like
const char *arr[] = { "string1", //some comment "string2", "string3" //another comment "string4", "string5" };
i.e. someone forgot, after "string3", and "string3" and "string4" are inserted together. Now, although this is completely legal code, is there a gcc warning flag or other tool that can scan the code base for such errors?
source share