From: Sandra Loosemore <sandra@codesourcery.com>
To: <gcc-patches@gcc.gnu.org>
Subject: [COMMITTED] Document negative forms of -Wtsan and -Wxor-used-as-pow [PR110847]
Date: Wed, 17 Jan 2024 19:34:24 -0700 [thread overview]
Message-ID: <20240118023424.1593073-1-sandra@codesourcery.com> (raw)
These warnings are enabled by default, thus the manual should document the
-no form instead of the positive form.
gcc/ChangeLog
PR middle-end/110847
* doc/invoke.texi (Option Summary): Document negative forms of
-Wtsan and -Wxor-used-as-pow.
(Warning Options): Likewise.
---
gcc/doc/invoke.texi | 22 +++++++++++-----------
1 file changed, 11 insertions(+), 11 deletions(-)
diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi
index a537be66736..4d43dda9839 100644
--- a/gcc/doc/invoke.texi
+++ b/gcc/doc/invoke.texi
@@ -410,7 +410,7 @@ Objective-C and Objective-C++ Dialects}.
-Wswitch -Wno-switch-bool -Wswitch-default -Wswitch-enum
-Wno-switch-outside-range -Wno-switch-unreachable -Wsync-nand
-Wsystem-headers -Wtautological-compare -Wtrampolines -Wtrigraphs
--Wtrivial-auto-var-init -Wtsan -Wtype-limits -Wundef
+-Wtrivial-auto-var-init -Wno-tsan -Wtype-limits -Wundef
-Wuninitialized -Wunknown-pragmas
-Wunsuffixed-float-constants -Wunused
-Wunused-but-set-parameter -Wunused-but-set-variable
@@ -424,7 +424,7 @@ Objective-C and Objective-C++ Dialects}.
-Wvector-operation-performance
-Wvla -Wvla-larger-than=@var{byte-size} -Wno-vla-larger-than
-Wvolatile-register-var -Wwrite-strings
--Wxor-used-as-pow
+-Wno-xor-used-as-pow
-Wzero-length-bounds}
@item Static Analyzer Options
@@ -9090,14 +9090,13 @@ This warning is enabled by default.
@opindex Wtsan
@opindex Wno-tsan
-@item -Wtsan
-Warn about unsupported features in ThreadSanitizer.
+@item -Wno-tsan
+
+Disable warnings about unsupported features in ThreadSanitizer.
ThreadSanitizer does not support @code{std::atomic_thread_fence} and
can report false positives.
-This warning is enabled by default.
-
@opindex Wtype-limits
@opindex Wno-type-limits
@item -Wtype-limits
@@ -10434,17 +10433,18 @@ and/or writes to register variables. This warning is enabled by
@opindex Wxor-used-as-pow
@opindex Wno-xor-used-as-pow
-@item -Wxor-used-as-pow @r{(C, C++, Objective-C and Objective-C++ only)}
-Warn about uses of @code{^}, the exclusive or operator, where it appears
-the user meant exponentiation. Specifically, the warning occurs when the
+@item -Wno-xor-used-as-pow @r{(C, C++, Objective-C and Objective-C++ only)}
+Disable warnings about uses of @code{^}, the exclusive or operator,
+where it appears the code meant exponentiation.
+Specifically, the warning occurs when the
left-hand side is the decimal constant 2 or 10 and the right-hand side
is also a decimal constant.
In C and C++, @code{^} means exclusive or, whereas in some other languages
(e.g. TeX and some versions of BASIC) it means exponentiation.
-This warning is enabled by default. It can be silenced by converting one
-of the operands to hexadecimal.
+This warning can be silenced by converting one of the operands to
+hexadecimal as well as by compiling with @option{-Wno-xor-used-as-pow}.
@opindex Wdisabled-optimization
@opindex Wno-disabled-optimization
--
2.31.1
reply other threads:[~2024-01-18 2:34 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240118023424.1593073-1-sandra@codesourcery.com \
--to=sandra@codesourcery.com \
--cc=gcc-patches@gcc.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).