diff mbox series

[committed] testsuite: Disable out-of-bounds checker in analyzer/torture/pr93451.c

Message ID 20220813120839.28527-1-mail@tim-lange.me
State New
Headers show
Series [committed] testsuite: Disable out-of-bounds checker in analyzer/torture/pr93451.c | expand

Commit Message

Tim Lange Aug. 13, 2022, 12:08 p.m. UTC
This patch disables Wanalyzer-out-of-bounds for analyzer/torture/pr93451.c
and makes the test case pass when compiled with -m32.

The emitted warning is a true positive but only occurs if
sizeof (long int) is less than sizeof (double). I've already discussed a
similar case with Dave in the context of pr96764.c and we came to the
conclusion that we just disable the checker in such cases.

Committed under the "obvious fix" rule.

gcc/testsuite/ChangeLog:

	* gcc.dg/analyzer/torture/pr93451.c:
	Disable Wanalyzer-out-of-bounds.

---
 gcc/testsuite/gcc.dg/analyzer/torture/pr93451.c | 2 ++
 1 file changed, 2 insertions(+)
diff mbox series

Patch

diff --git a/gcc/testsuite/gcc.dg/analyzer/torture/pr93451.c b/gcc/testsuite/gcc.dg/analyzer/torture/pr93451.c
index 5908bc4b69f..daac745d504 100644
--- a/gcc/testsuite/gcc.dg/analyzer/torture/pr93451.c
+++ b/gcc/testsuite/gcc.dg/analyzer/torture/pr93451.c
@@ -1,3 +1,5 @@ 
+/* { dg-additional-options "-Wno-analyzer-out-of-bounds" } */
+
 void
 mt (double);