aboutsummaryrefslogtreecommitdiffstats
path: root/translate/grt/grt-rtis_utils.adb
diff options
context:
space:
mode:
Diffstat (limited to 'translate/grt/grt-rtis_utils.adb')
-rw-r--r--translate/grt/grt-rtis_utils.adb20
1 files changed, 9 insertions, 11 deletions
diff --git a/translate/grt/grt-rtis_utils.adb b/translate/grt/grt-rtis_utils.adb
index d01cea9e5..dbc70c2c6 100644
--- a/translate/grt/grt-rtis_utils.adb
+++ b/translate/grt/grt-rtis_utils.adb
@@ -169,7 +169,8 @@ package body Grt.Rtis_Utils is
procedure Foreach_Scalar (Ctxt : Rti_Context;
Obj_Type : Ghdl_Rti_Access;
Obj_Addr : Address;
- Is_Sig : Boolean)
+ Is_Sig : Boolean;
+ Param : Param_Type)
is
-- Current address.
Addr : Address;
@@ -185,7 +186,7 @@ package body Grt.Rtis_Utils is
Addr := Addr + (S / Storage_Unit);
end Update;
begin
- Process (Addr, Name, Rti);
+ Process (Addr, Name, Rti, Param);
if Is_Sig then
Update (Address'Size);
@@ -448,18 +449,15 @@ package body Grt.Rtis_Utils is
declare
S : String (1 .. 32);
L : Integer;
- -- Warning: this assumes a C99 snprintf (ie, it returns the
- -- number of characters).
- function snprintf (Cstr : Address;
- Size : Natural;
- Template : Address;
- Arg : Ghdl_F64)
+
+ function Snprintf_G (Cstr : Address;
+ Size : Natural;
+ Arg : Ghdl_F64)
return Integer;
- pragma Import (C, snprintf);
+ pragma Import (C, Snprintf_G, "__ghdl_snprintf_g");
- Format : constant String := "%g" & Character'Val (0);
begin
- L := snprintf (S'Address, S'Length, Format'Address, Value.F64);
+ L := Snprintf_G (S'Address, S'Length, Value.F64);
if L < 0 then
-- FIXME.
Append (Str, "?");