https://gcc.gnu.org/bugzilla/show_bug.cgi?id=128457

--- Comment #6 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-14 branch has been updated by Eric Botcazou
<[email protected]>:

https://gcc.gnu.org/g:b7c175269bbf3985913fef0bf6c4b37f548ed347

commit r14-13000-gb7c175269bbf3985913fef0bf6c4b37f548ed347
Author: Andrea Boido <[email protected]>
Date:   Thu Nov 5 13:36:22 2026 +0000

    Ada: Fix membership test with universal_real tested expression

    This changes the special resolution of membership tests whose tested
    expression is of a universal numeric type, which skips the rounding to
    the tested type required by RM 4.9(38) for universal_real.  The special
    resolution is now restricted to universal_integer, since the range check
    failure it avoids cannot occur for real types in practice.

    gcc/ada/
            PR ada/128457
            * sem_res.adb (Resolve_Membership_Op): Only perform the special
            resolution if the left operand is of type universal_integer and
            the right operand is of a smaller integer type.

    gcc/testsuite/
            * gnat.dg/membership_real1.adb: New test.

Reply via email to