[gcc r15-1156] ada: Minor code adjustment to "not Present" test

Marc Poulhi?s dkm@gcc.gnu.org
Mon Jun 10 09:09:15 GMT 2024


https://gcc.gnu.org/g:9bf9e60e262f54d87b146a2a322a8ad6324301ea

commit r15-1156-g9bf9e60e262f54d87b146a2a322a8ad6324301ea
Author: Gary Dismukes <dismukes@adacore.com>
Date:   Wed Apr 17 21:24:21 2024 +0000

    ada: Minor code adjustment to "not Present" test
    
    This is just changing a "not Present (...)" test to "No (...)"
    to address a CB complaint from gnatcheck.
    
    gcc/ada/
    
            * sem_aggr.adb (Resolve_Iterated_Association): Change "not Present"
            to "No" in test of Add_Named_Subp.

Diff:
---
 gcc/ada/sem_aggr.adb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gcc/ada/sem_aggr.adb b/gcc/ada/sem_aggr.adb
index 51b88ab831f..249350d21de 100644
--- a/gcc/ada/sem_aggr.adb
+++ b/gcc/ada/sem_aggr.adb
@@ -3380,7 +3380,7 @@ package body Sem_Aggr is
 
             Key_Expr := Key_Expression (Comp);
             if Present (Key_Expr) then
-               if not Present (Add_Named_Subp) then
+               if No (Add_Named_Subp) then
                   Error_Msg_N
                     ("iterated_element_association with key_expression only "
                        & "allowed for container type with Add_Named operation "


More information about the Gcc-cvs mailing list