]> git.ipfire.org Git - thirdparty/gcc.git/commit
ada: Guard compile-time evaluator against rewritten if-expressions
authorPiotr Trojanek <trojanek@adacore.com>
Wed, 22 Oct 2025 15:38:04 +0000 (17:38 +0200)
committerMarc Poulhiès <dkm@gcc.gnu.org>
Mon, 3 Nov 2025 14:15:18 +0000 (15:15 +0100)
commit85b6344379e7463c7cca0d731a09e122467dc1b6
tree1d33a00fdb5dc2b95b1bdbdc999c49544e4563a0
parentfd7b43f5f4a3a9d3f928cd113730208484dc2889
ada: Guard compile-time evaluator against rewritten if-expressions

A hopefully temporary fix for if-expression that has been rewritten into an
if-statement, where a object reference has the if-statement as its parent,
but is not part of the condition, then statements or else statements.

gcc/ada/ChangeLog:

* exp_util.adb (Get_Current_Value_Condition): Guard against orphaned
references in rewritten if-expressions.
gcc/ada/exp_util.adb