Subject: Re: g++: What command line option allow me to get the most friendly/responsive compiling error message?
On 2026-04-27 11:27, ??Jacek Marcin Jaworski?? wrote:
Hello!
What g++ command line option allow me to get the most
friendly/responsive compiling error message? I use:
-Wformat=2
which is not very friendly.
That is a highly subjective opinion. You'll get different answers from different people. In general, each person's answer is "right" for that
person, but not necessarily for anyone else. I normally build using
make, which looks for and uses an environment variable named CXXFLAGS
when compiling C++ code, and I've got CXXFLAGS set to:
-std=c++23 -pedantic -Wall -O2 -Wpointer-arith -Wcast-align -fno-enforce-eh-specs -fno-gnu-keywords -fno-nonansi-builtins -Wctor-dtor-privacy -Wnon-virtual-dtor -Wold-style-cast
-Woverloaded-virtual -Wsign-promo
I guarantee you that my posting that list of options will cause many
people to disagree - whether they'll bother saying so, I don't know.
--- PyGate Linux v1.5.14
* Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)