My compiler (gcc) is giving me this warning. Please help me to understand what it means:
warning: trigraph ??/ ignored, use -trigraphs to enable
My compiler (gcc) is giving me this warning. Please help me to understand what it means:
warning: trigraph ??/ ignored, use -trigraphs to enable
You have "accidentally" written a trigraph somewhere in your source code (the compiler's warning would pinpoint the line). Since trigraphs were invented to solve a problem that doesn't come into play on modern systems, you don't actually want the trigraph ??/
to be replaced with the character \
.
Therefore, this warning should probably be ignored (you can tell the compiler to shut up by adding -Wno-trigraphs
after -Wall
in your command line; see the docs). But it would be good to show your source code so we can be sure.
Instead of adding a compiler flag, you could just escape each question mark with \
, i.e. \?\?-
. This helped in my case.
© 2022 - 2024 — McMap. All rights reserved.
??/
is the equivalent of backslash, you can replace the triagraph to "\" – Privative