From 9cdffbc8e4a21e2ebd91c33264a250b3d0328129 Mon Sep 17 00:00:00 2001 From: charlet Date: Mon, 30 Nov 2009 10:07:32 +0000 Subject: 2009-11-30 Thomas Quinot * s-crtl.ads, g-stseme.adb, s-fileio.adb (System.CRTL.strerror): Change return type to Interfaces.C.Strings.chars_ptr to eliminate need for dubious unchecked conversion at call sites. * s-errrep.adb, s-errrep.ads, Makefile.rtl (System.Error_Reporting): Remove obsolete, unused runtime unit. * gcc-interface/Make-lang.in: Update dependencies. * gcc-interface/Makefile.in: Remove VMS specialization of s-crtl, not required anymore. 2009-11-30 Vincent Celier * gnatlink.adb: Delete an eventual existing executable file, in case it is a symbolic link, to avoid modifying the target of the symbolic link. 2009-11-30 Bob Duff * socket.c: Add accessor functions for struct servent. * g-sothco.ads (Servent): Declare interfaces to C accessor functions for struct servent. * g-socket.adb (To_Service_Entry): Use accessor functions for struct servent. 2009-11-30 Robert Dewar * g-arrspl.adb: Minor reformatting * g-dyntab.adb: Add missing pragma Compiler_Unit git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@154769 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/ada/s-crtl.ads | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'gcc/ada/s-crtl.ads') diff --git a/gcc/ada/s-crtl.ads b/gcc/ada/s-crtl.ads index 4ad2ceed3b1..bb0700a85a4 100644 --- a/gcc/ada/s-crtl.ads +++ b/gcc/ada/s-crtl.ads @@ -31,13 +31,18 @@ -- This package provides the low level interface to the C runtime library +with Interfaces.C.Strings; + with System.Parameters; package System.CRTL is pragma Preelaborate; + subtype chars_ptr is Interfaces.C.Strings.chars_ptr; + subtype chars is System.Address; -- Pointer to null-terminated array of characters + -- Should use Interfaces.C.Strings types instead??? subtype DIRs is System.Address; -- Corresponds to the C type DIR* @@ -48,7 +53,7 @@ package System.CRTL is subtype int is Integer; type long is range -(2 ** (System.Parameters.long_bits - 1)) - .. +(2 ** (System.Parameters.long_bits - 1)) - 1; + .. +(2 ** (System.Parameters.long_bits - 1)) - 1; subtype off_t is Long_Integer; @@ -190,7 +195,7 @@ package System.CRTL is function write (fd : int; buffer : chars; nbytes : int) return int; pragma Import (C, write, "write"); - function strerror (errno : int) return chars; + function strerror (errno : int) return chars_ptr; pragma Import (C, strerror, "strerror"); end System.CRTL; -- cgit v1.2.1