Commit a8c316b2 by Arnaud Charlet Committed by Pierre-Marie de Rodat

[Ada] Memtrack: have only one definition of fwrite

2018-06-11  Arnaud Charlet  <charlet@adacore.com>

gcc/ada/

	* libgnat/memtrack.adb (fwrite): Remove second definition.

From-SVN: r261407
parent 7ffe26fc
2018-06-11 Arnaud Charlet <charlet@adacore.com>
* libgnat/memtrack.adb (fwrite): Remove second definition.
2018-06-11 Javier Miranda <miranda@adacore.com>
* sinfo.ads (Is_Dynamic_Coextension): Adding documentation.
......
......@@ -107,12 +107,6 @@ package body System.Memory is
Size : size_t;
Nmemb : size_t;
Stream : File_Ptr);
procedure fwrite
(Str : String;
Size : size_t;
Nmemb : size_t;
Stream : File_Ptr);
pragma Import (C, fwrite);
procedure fputc (C : Integer; Stream : File_Ptr);
......@@ -306,9 +300,13 @@ package body System.Memory is
OS_Exit (255);
end if;
fwrite ("GMEM DUMP" & ASCII.LF, 10, 1, Gmemfile);
fwrite (Timestamp'Address, Duration'Max_Size_In_Storage_Elements, 1,
Gmemfile);
declare
S : constant String := "GMEM DUMP" & ASCII.LF;
begin
fwrite (S'Address, S'Length, 1, Gmemfile);
fwrite (Timestamp'Address, Duration'Max_Size_In_Storage_Elements,
1, Gmemfile);
end;
end if;
end Gmem_Initialize;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment