diff options
author | Jerry DeLisle <jvdelisle@gcc.gnu.org> | 2025-09-02 15:58:26 -0700 |
---|---|---|
committer | Jerry DeLisle <jvdelisle@gcc.gnu.org> | 2025-09-02 15:58:26 -0700 |
commit | 071b4126c613881f4cb25b4e5c39032964827f88 (patch) | |
tree | 7ed805786566918630d1d617b1ed8f7310f5fd8e /gcc/ada/treepr.adb | |
parent | 845d23f3ea08ba873197c275a8857eee7edad996 (diff) | |
parent | caa1c2f42691d68af4d894a5c3e700ecd2dba080 (diff) | |
download | gcc-devel/gfortran-test.zip gcc-devel/gfortran-test.tar.gz gcc-devel/gfortran-test.tar.bz2 |
Merge branch 'master' into gfortran-testdevel/gfortran-test
Diffstat (limited to 'gcc/ada/treepr.adb')
-rw-r--r-- | gcc/ada/treepr.adb | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/gcc/ada/treepr.adb b/gcc/ada/treepr.adb index 375608d..857b926 100644 --- a/gcc/ada/treepr.adb +++ b/gcc/ada/treepr.adb @@ -1600,19 +1600,17 @@ package body Treepr is -- If this is a discrete expression whose value is known, print that -- value. - if Nkind (N) in N_Subexpr + if ((Is_Entity_Name (N) -- e.g. enumeration literal + and then Present (Entity (N))) + or else Nkind (N) in N_Integer_Literal + | N_Character_Literal + | N_Unchecked_Type_Conversion) and then Compile_Time_Known_Value (N) and then Present (Etype (N)) and then Is_Discrete_Type (Etype (N)) then - if Is_Entity_Name (N) -- e.g. enumeration literal - or else Nkind (N) in N_Integer_Literal - | N_Character_Literal - | N_Unchecked_Type_Conversion - then - Print_Str (" val = "); - UI_Write (Expr_Value (N)); - end if; + Print_Str (" val = "); + UI_Write (Expr_Value (N)); end if; if Nkind (N) in N_Entity then |