summaryrefslogtreecommitdiff
path: root/gcc/ada/a-ztexio.adb
diff options
context:
space:
mode:
authorThomas Quinot <quinot@adacore.com>2008-05-27 12:14:25 +0200
committerArnaud Charlet <charlet@gcc.gnu.org>2008-05-27 12:14:25 +0200
commite2baae4e1c8be8158233435d500f288a786a1121 (patch)
treef8477ecfb2c883ca1bd8ae86692e823bda30959f /gcc/ada/a-ztexio.adb
parentab8bfb6497bde60fdaa99b684e499e4748cffe49 (diff)
downloadgcc-e2baae4e1c8be8158233435d500f288a786a1121.tar.gz
(System.File_IO.{Close, Delete, Reset}): Change File parameter from "in out AFCB_Ptr" to "access AFCB_Ptr".
2008-05-27 Thomas Quinot <quinot@adacore.com> (System.File_IO.{Close, Delete, Reset}): Change File parameter from "in out AFCB_Ptr" to "access AFCB_Ptr". (Ada.*_IO.{Close, Delete, Reset, Set_Mode}): Pass File parameter by reference. From-SVN: r136002
Diffstat (limited to 'gcc/ada/a-ztexio.adb')
-rw-r--r--gcc/ada/a-ztexio.adb20
1 files changed, 16 insertions, 4 deletions
diff --git a/gcc/ada/a-ztexio.adb b/gcc/ada/a-ztexio.adb
index a85cdb30998..8db57b94689 100644
--- a/gcc/ada/a-ztexio.adb
+++ b/gcc/ada/a-ztexio.adb
@@ -133,8 +133,11 @@ package body Ada.Wide_Wide_Text_IO is
-----------
procedure Close (File : in out File_Type) is
+ AFCB : aliased AP;
+ for AFCB'Address use File'Address;
+ pragma Import (Ada, AFCB);
begin
- FIO.Close (AP (File));
+ FIO.Close (AFCB'Access);
end Close;
---------
@@ -232,8 +235,11 @@ package body Ada.Wide_Wide_Text_IO is
------------
procedure Delete (File : in out File_Type) is
+ AFCB : aliased AP;
+ for AFCB'Address use File'Address;
+ pragma Import (Ada, AFCB);
begin
- FIO.Delete (AP (File));
+ FIO.Delete (AFCB'Access);
end Delete;
-----------------
@@ -1308,6 +1314,9 @@ package body Ada.Wide_Wide_Text_IO is
(File : in out File_Type;
Mode : File_Mode)
is
+ AFCB : aliased AP;
+ for AFCB'Address use File'Address;
+ pragma Import (Ada, AFCB);
begin
-- Don't allow change of mode for current file (RM A.10.2(5))
@@ -1320,7 +1329,7 @@ package body Ada.Wide_Wide_Text_IO is
end if;
Terminate_Line (File);
- FIO.Reset (AP (File), To_FCB (Mode));
+ FIO.Reset (AFCB'Access, To_FCB (Mode));
File.Page := 1;
File.Line := 1;
File.Col := 1;
@@ -1331,9 +1340,12 @@ package body Ada.Wide_Wide_Text_IO is
end Reset;
procedure Reset (File : in out File_Type) is
+ AFCB : aliased AP;
+ for AFCB'Address use File'Address;
+ pragma Import (Ada, AFCB);
begin
Terminate_Line (File);
- FIO.Reset (AP (File));
+ FIO.Reset (AFCB'Access);
File.Page := 1;
File.Line := 1;
File.Col := 1;