]> gcc.gnu.org Git - gcc.git/commit
ada: Spurious reference warning on qualified expression
authorJustin Squirek <squirek@adacore.com>
Thu, 21 Dec 2023 18:31:27 +0000 (18:31 +0000)
committerMarc Poulhiès <poulhies@adacore.com>
Mon, 6 May 2024 09:11:29 +0000 (11:11 +0200)
commit0b7c0811ced8c98b4bebd1bc89f2272216000900
tree969481f5c0fda9563b3077eb03c63bfc15fad09d
parent625d5f98d74863ca580008f3566768f46da2c109
ada: Spurious reference warning on qualified expression

This patch fixes an error in the compiler whereby an assignment to an out
formal (whose type requires a predicate check) can lead to spurious
"value may be referenced before it has a value" warnings when the RHS is a
qualified expression.

gcc/ada/

* sem_warn.adb (Within_Postcondition): Add case to ignore
references within generated predicate function calls.
gcc/ada/sem_warn.adb
This page took 0.061862 seconds and 6 git commands to generate.