]> gcc.gnu.org Git - gcc.git/commit
ada: Operator visibility bug in static expression functions
authorSteve Baird <baird@adacore.com>
Mon, 24 Jun 2024 18:57:59 +0000 (11:57 -0700)
committerMarc Poulhiès <dkm@gcc.gnu.org>
Thu, 1 Aug 2024 15:14:35 +0000 (17:14 +0200)
commited8612ac09baa12d025a019b43acec975978ce9e
treea422524c4c9c2ee0ef3891409bab77c907dbb6f4
parent53b215c0ca2792a0fd838be6e331d735bad409c7
ada: Operator visibility bug in static expression functions

In some cases, an expanded name refering to a predefined operator (such as
Some_Package."+") occurring in a static expression function would be
incorrectly rejected with a message saying that the operator is not directly
visible (which, while True, does not make the reference illegal).

gcc/ada/

* sem_ch4.adb (Is_Effectively_Visible_Opertor): Return True if
Checking_Potentially_Static_Expression is True. The accompanying
comment says True is returned "if there is a reason it is ok for
Is_Visible_Operator to return False"; if
Checking_Potentially_Static_Expression is true, that is such a
reason.
gcc/ada/sem_ch4.adb
This page took 0.055817 seconds and 5 git commands to generate.