summaryrefslogtreecommitdiffstats
path: root/gcc/ada/s-imgint.ads
diff options
context:
space:
mode:
authorcharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2007-12-13 10:30:04 +0000
committercharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2007-12-13 10:30:04 +0000
commit830a3f424d271773b4efa216a3006b108d48d04f (patch)
tree723bf7b7f6c79be9da7af8b7b5180dc8dc0f63f7 /gcc/ada/s-imgint.ads
parent587185fc9008481f0b72ec5dcf732420b1a92288 (diff)
downloadppe42-gcc-830a3f424d271773b4efa216a3006b108d48d04f.tar.gz
ppe42-gcc-830a3f424d271773b4efa216a3006b108d48d04f.zip
2007-12-06 Robert Dewar <dewar@adacore.com>
* s-imenne.adb, s-imenne.ads: New files. * s-imgboo.adb, s-imgboo.ads, s-imgcha.adb, s-imgcha.ads, s-imgdec.adb, s-imgdec.ads, s-imgenu.ads, s-imgint.adb, s-imgint.ads, s-imglld.adb, s-imglld.ads, s-imglli.adb, s-imglli.ads, s-imgllu.adb, s-imgllu.ads, s-imgrea.adb, s-imgrea.ads, s-imguns.adb, s-imguns.ads, s-imgwch.adb, s-imgwch.ads: New calling sequence for Image routines to avoid sec stack usage. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@130852 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/s-imgint.ads')
-rw-r--r--gcc/ada/s-imgint.ads24
1 files changed, 14 insertions, 10 deletions
diff --git a/gcc/ada/s-imgint.ads b/gcc/ada/s-imgint.ads
index a9e35211be8..7fe23186ea9 100644
--- a/gcc/ada/s-imgint.ads
+++ b/gcc/ada/s-imgint.ads
@@ -6,7 +6,7 @@
-- --
-- S p e c --
-- --
--- Copyright (C) 1992-2005 Free Software Foundation, Inc. --
+-- Copyright (C) 1992-2007, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
@@ -38,18 +38,22 @@
package System.Img_Int is
pragma Pure;
- function Image_Integer (V : Integer) return String;
- -- Computes Integer'Image (V) and returns the result
+ procedure Image_Integer
+ (V : Integer;
+ S : in out String;
+ P : out Natural);
+ -- Computes Integer'Image (V) and stores the result in S (1 .. P)
+ -- setting the resulting value of P. The caller guarantees that S
+ -- is long enough to hold the result, and that S'First is 1.
procedure Set_Image_Integer
(V : Integer;
- S : out String;
+ S : in out String;
P : in out Natural);
- -- Sets the image of V starting at S (P + 1) with no leading spaces (i.e.
- -- Text_IO format where Width = 0), starting at S (P + 1), updating P
- -- to point to the last character stored. The caller promises that the
- -- buffer is large enough and no check is made for this (Constraint_Error
- -- will not be necessarily raised if this is violated since it is perfectly
- -- valid to compile this unit with checks off).
+ -- Stores the image of V in S starting at S (P + 1), P is updated to point
+ -- to the last character stored. The value stored is identical to the value
+ -- of Integer'Image (V) except that no leading space is stored when V is
+ -- non-negative. The caller guarantees that S is long enough to hold the
+ -- result. S need not have a lower bound of 1.
end System.Img_Int;
OpenPOWER on IntegriCloud