2 Commits

Author SHA1 Message Date
Iris Shi
f9088f1eb5
[static analyzer] Fix crash on parenthesized expression in assume attribute (#151682)
- Closes #151529

`ParenExpr` should be ignored before reaching `ExprEngine::Visit`.
Failing to do so triggers the assertion.
2025-08-01 19:29:06 +08:00
Donát Nagy
405c28bb10
[NFC][analyzer] Split [[assume]] tests to a separate file (#130763)
Recently commit 7e5821bae80db3f3f0fe0d5f8ce62f79e548eed5 (which is a
re-application of 89da344e5879e5347b5057520d5230e40ae24831) added some
tests to `out-of-bounds-new.cpp`, which use a very simple out of bounds
report to reveal the internal state of the analyzer, but are otherwise
completely unrelated to the checker `security.ArrayBound`, which is
tested in `out-of-bounds-new.cpp`.

(Instead, they test handling of `__builtin_assume` and `[[assume()]]`
annotations.)

This commit reverts `out-of-bounds-new.cpp` to its previous state and
moves the new tests to a separate test file.
2025-03-11 13:52:55 +01:00