]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/ada/s-imglld.ads
Licensing changes to GPLv3 resp. GPLv3 with GCC Runtime Exception.
[thirdparty/gcc.git] / gcc / ada / s-imglld.ads
CommitLineData
cacbc350
RK
1------------------------------------------------------------------------------
2-- --
3084fecd 3-- GNAT RUN-TIME COMPONENTS --
cacbc350
RK
4-- --
5-- S Y S T E M . I M G _ L L D --
6-- --
7-- S p e c --
8-- --
748086b7 9-- Copyright (C) 1992-2009, Free Software Foundation, Inc. --
cacbc350
RK
10-- --
11-- GNAT is free software; you can redistribute it and/or modify it under --
12-- terms of the GNU General Public License as published by the Free Soft- --
748086b7 13-- ware Foundation; either version 3, or (at your option) any later ver- --
cacbc350
RK
14-- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
15-- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
748086b7 16-- or FITNESS FOR A PARTICULAR PURPOSE. --
cacbc350 17-- --
748086b7
JJ
18-- As a special exception under Section 7 of GPL version 3, you are granted --
19-- additional permissions described in the GCC Runtime Library Exception, --
20-- version 3.1, as published by the Free Software Foundation. --
21-- --
22-- You should have received a copy of the GNU General Public License and --
23-- a copy of the GCC Runtime Library Exception along with this program; --
24-- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see --
25-- <http://www.gnu.org/licenses/>. --
cacbc350
RK
26-- --
27-- GNAT was originally developed by the GNAT team at New York University. --
71ff80dc 28-- Extensive contributions were provided by Ada Core Technologies Inc. --
cacbc350
RK
29-- --
30------------------------------------------------------------------------------
31
32-- Image for decimal fixed types where the size of the corresponding integer
33-- type does exceeds Integer'Size (also used for Text_IO.Decimal_IO output)
34
35package System.Img_LLD is
01b18343 36 pragma Pure;
cacbc350 37
01b18343 38 procedure Image_Long_Long_Decimal
cacbc350 39 (V : Long_Long_Integer;
01b18343
RD
40 S : in out String;
41 P : out Natural;
42 Scale : Integer);
43 -- Computes fixed_type'Image (V), where V is the integer value (in units of
44 -- delta) of a decimal type whose Scale is as given and store the result in
45 -- S (P + 1 .. L), updating P to the value of L. The image is given by the
46 -- rules in RM 3.5(34) for fixed-point type image functions. The caller
47 -- guarantees that S is long enough to hold the result. S need not have a
48 -- lower bound of 1.
cacbc350
RK
49
50 procedure Set_Image_Long_Long_Decimal
51 (V : Long_Long_Integer;
01b18343 52 S : in out String;
cacbc350
RK
53 P : in out Natural;
54 Scale : Integer;
55 Fore : Natural;
56 Aft : Natural;
57 Exp : Natural);
58 -- Sets the image of V, where V is the integer value (in units of delta)
59 -- of a decimal type with the given Scale, starting at S (P + 1), updating
60 -- P to point to the last character stored, the caller promises that the
61 -- buffer is large enough and no check is made for this. Constraint_Error
62 -- will not necessarily be raised if this requirement is violated, since
63 -- it is perfectly valid to compile this unit with checks off. The Fore,
64 -- Aft and Exp values can be set to any valid values for the case of use
01b18343 65 -- by Text_IO.Decimal_IO. Note that there is no leading space stored.
cacbc350
RK
66
67end System.Img_LLD;