aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/repinfo.adb
diff options
context:
space:
mode:
authorEric Botcazou <ebotcazou@adacore.com>2019-07-23 08:13:21 +0000
committerPierre-Marie de Rodat <pmderodat@gcc.gnu.org>2019-07-23 08:13:21 +0000
commitf9534f4bd63c9f4be7816f0f9bd8a5feeded5821 (patch)
tree1ab1609054c47242f22390ce0dc993f5d614854a /gcc/ada/repinfo.adb
parentc910db716273c381b4e2f36f3d04c6e480876b63 (diff)
downloadgcc-f9534f4bd63c9f4be7816f0f9bd8a5feeded5821.zip
gcc-f9534f4bd63c9f4be7816f0f9bd8a5feeded5821.tar.gz
gcc-f9534f4bd63c9f4be7816f0f9bd8a5feeded5821.tar.bz2
[Ada] Minor tweak to -gnatR output
This makes sure that the numbers present in the -gnatR output are printed in decimal format in all cases, since the hexadecimal format is not compatible with the JSON syntax. 2019-07-23 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * repinfo.adb (List_Component_Layout): Pass Decimal to UI_Write. (Write_Val): Likewise. From-SVN: r273723
Diffstat (limited to 'gcc/ada/repinfo.adb')
-rw-r--r--gcc/ada/repinfo.adb12
1 files changed, 6 insertions, 6 deletions
diff --git a/gcc/ada/repinfo.adb b/gcc/ada/repinfo.adb
index a277bab..77b5c21 100644
--- a/gcc/ada/repinfo.adb
+++ b/gcc/ada/repinfo.adb
@@ -1150,7 +1150,7 @@ package body Repinfo is
if Ekind (Ent) = E_Discriminant then
Spaces (Indent);
Write_Str (" ""discriminant"": ");
- UI_Write (Discriminant_Number (Ent));
+ UI_Write (Discriminant_Number (Ent), Decimal);
Write_Line (",");
end if;
Spaces (Indent);
@@ -1181,7 +1181,7 @@ package body Repinfo is
Spaces (Max_Spos_Length - 2);
if Starting_Position /= Uint_0 then
- UI_Write (Starting_Position);
+ UI_Write (Starting_Position, Decimal);
Write_Str (" + ");
end if;
@@ -1205,7 +1205,7 @@ package body Repinfo is
Sbit := Sbit - SSU;
end if;
- UI_Write (Sbit);
+ UI_Write (Sbit, Decimal);
if List_Representation_Info_To_JSON then
Write_Line (", ");
@@ -1227,13 +1227,13 @@ package body Repinfo is
Lbit := Sbit + Esiz - 1;
if List_Representation_Info_To_JSON then
- UI_Write (Esiz);
+ UI_Write (Esiz, Decimal);
else
if Lbit >= 0 and then Lbit < 10 then
Write_Char (' ');
end if;
- UI_Write (Lbit);
+ UI_Write (Lbit, Decimal);
end if;
-- The test for Esize (Ent) not Uint_0 here is an annoying special
@@ -2414,7 +2414,7 @@ package body Repinfo is
end if;
else
- UI_Write (Val);
+ UI_Write (Val, Decimal);
end if;
end Write_Val;