Daily bump.
[official-gcc.git] / gcc / ada / a-chahan.ads
blobe5a5de8e7b86ae39dee23fe47577d4720365a883
1 ------------------------------------------------------------------------------
2 -- --
3 -- GNAT RUN-TIME COMPONENTS --
4 -- --
5 -- A D A . C H A R A C T E R S . H A N D L I N G --
6 -- --
7 -- S p e c --
8 -- --
9 -- $Revision: 1.1.16.1 $
10 -- --
11 -- Copyright (C) 1992-1997 Free Software Foundation, Inc. --
12 -- --
13 -- This specification is derived from the Ada Reference Manual for use with --
14 -- GNAT. The copyright notice above, and the license provisions that follow --
15 -- apply solely to the contents of the part following the private keyword. --
16 -- --
17 -- GNAT is free software; you can redistribute it and/or modify it under --
18 -- terms of the GNU General Public License as published by the Free Soft- --
19 -- ware Foundation; either version 2, or (at your option) any later ver- --
20 -- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
21 -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
22 -- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License --
23 -- for more details. You should have received a copy of the GNU General --
24 -- Public License distributed with GNAT; see file COPYING. If not, write --
25 -- to the Free Software Foundation, 59 Temple Place - Suite 330, Boston, --
26 -- MA 02111-1307, USA. --
27 -- --
28 -- As a special exception, if other files instantiate generics from this --
29 -- unit, or you link this unit with other files to produce an executable, --
30 -- this unit does not by itself cause the resulting executable to be --
31 -- covered by the GNU General Public License. This exception does not --
32 -- however invalidate any other reasons why the executable file might be --
33 -- covered by the GNU Public License. --
34 -- --
35 -- GNAT was originally developed by the GNAT team at New York University. --
36 -- Extensive contributions were provided by Ada Core Technologies Inc. --
37 -- --
38 ------------------------------------------------------------------------------
41 package Ada.Characters.Handling is
42 pragma Preelaborate (Handling);
44 ----------------------------------------
45 -- Character Classification Functions --
46 ----------------------------------------
48 function Is_Control (Item : in Character) return Boolean;
49 function Is_Graphic (Item : in Character) return Boolean;
50 function Is_Letter (Item : in Character) return Boolean;
51 function Is_Lower (Item : in Character) return Boolean;
52 function Is_Upper (Item : in Character) return Boolean;
53 function Is_Basic (Item : in Character) return Boolean;
54 function Is_Digit (Item : in Character) return Boolean;
55 function Is_Decimal_Digit (Item : in Character) return Boolean
56 renames Is_Digit;
57 function Is_Hexadecimal_Digit (Item : in Character) return Boolean;
58 function Is_Alphanumeric (Item : in Character) return Boolean;
59 function Is_Special (Item : in Character) return Boolean;
61 ---------------------------------------------------
62 -- Conversion Functions for Character and String --
63 ---------------------------------------------------
65 function To_Lower (Item : in Character) return Character;
66 function To_Upper (Item : in Character) return Character;
67 function To_Basic (Item : in Character) return Character;
69 function To_Lower (Item : in String) return String;
70 function To_Upper (Item : in String) return String;
71 function To_Basic (Item : in String) return String;
73 ----------------------------------------------------------------------
74 -- Classifications of and Conversions Between Character and ISO 646 --
75 ----------------------------------------------------------------------
77 subtype ISO_646 is
78 Character range Character'Val (0) .. Character'Val (127);
80 function Is_ISO_646 (Item : in Character) return Boolean;
81 function Is_ISO_646 (Item : in String) return Boolean;
83 function To_ISO_646
84 (Item : in Character;
85 Substitute : in ISO_646 := ' ')
86 return ISO_646;
88 function To_ISO_646
89 (Item : in String;
90 Substitute : in ISO_646 := ' ')
91 return String;
93 ------------------------------------------------------
94 -- Classifications of Wide_Character and Characters --
95 ------------------------------------------------------
97 function Is_Character (Item : in Wide_Character) return Boolean;
98 function Is_String (Item : in Wide_String) return Boolean;
100 ------------------------------------------------------
101 -- Conversions between Wide_Character and Character --
102 ------------------------------------------------------
104 function To_Character
105 (Item : in Wide_Character;
106 Substitute : in Character := ' ')
107 return Character;
109 function To_String
110 (Item : in Wide_String;
111 Substitute : in Character := ' ')
112 return String;
114 function To_Wide_Character (Item : in Character) return Wide_Character;
115 function To_Wide_String (Item : in String) return Wide_String;
117 private
118 pragma Inline (Is_Control);
119 pragma Inline (Is_Graphic);
120 pragma Inline (Is_Letter);
121 pragma Inline (Is_Lower);
122 pragma Inline (Is_Upper);
123 pragma Inline (Is_Basic);
124 pragma Inline (Is_Digit);
125 pragma Inline (Is_Hexadecimal_Digit);
126 pragma Inline (Is_Alphanumeric);
127 pragma Inline (Is_Special);
128 pragma Inline (To_Lower);
129 pragma Inline (To_Upper);
130 pragma Inline (To_Basic);
131 pragma Inline (Is_ISO_646);
132 pragma Inline (Is_Character);
133 pragma Inline (To_Character);
134 pragma Inline (To_Wide_Character);
136 end Ada.Characters.Handling;