News for hackers. Stuff that matters.
Re:A list of modern C++ features by lorenzhs on Monday November 14, 2016 @11:07AM (#12950665)
-Wc++98-compat is especially annoying.
Re:A list of modern C++ features by uabstraction on Monday November 14, 2016 @12:34PM (#12951539)
You guys don't use -pedantic? :D
Re:A list of modern C++ features by lorenzhs on Monday November 14, 2016 @02:57PM (#12952714)
-Weverything is even more pedantic than -pedantic: http://clang.llvm.org/docs/UsersManual.html#diagnostics-enab... - pedantic can be a bit annoying, but Weverything is downright infuriating on a modern codebase
Re:A list of modern C++ features by cygx on Monday November 14, 2016 @10:06PM (#12955294)
That's why you combine it with -Wno-... as appropriate on a per-project as well as per-file basis in addition to a simple way to disable warnings completely.

When using make, it could look something like this:

    CC := clang
    CFLAGS := -std=c99
    WFLAGS := -Weverything -Werror
    NOWARN := vla
    COMPILE = $(CC) -c $(CFLAGS) $(WFLAGS) $(NOWARN:%=-Wno-%) -o $@ $<

    foo.o: NOWARN += padded

    foo.o bar.o: %.o: %.c
        $(COMPILE)
Building without warnings would be achieved via

    make WFLAGS=""