Update concepts branch to revision 131834
[official-gcc.git] / gcc / ada / s-ststop.ads
blobf954bccfc7b000a6dffa557c48cd867ae7ef1daa
1 ------------------------------------------------------------------------------
2 -- --
3 -- GNAT RUN-TIME LIBRARY (GNARL) COMPONENTS --
4 -- --
5 -- S Y S T E M . S T R I N G S . S T R E A M _ O P S --
6 -- --
7 -- S p e c --
8 -- --
9 -- Copyright (C) 2008, Free Software Foundation, Inc. --
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- --
13 -- ware Foundation; either version 2, or (at your option) any later ver- --
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 --
16 -- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License --
17 -- for more details. You should have received a copy of the GNU General --
18 -- Public License distributed with GNAT; see file COPYING. If not, write --
19 -- to the Free Software Foundation, 51 Franklin Street, Fifth Floor, --
20 -- Boston, MA 02110-1301, USA. --
21 -- --
22 -- As a special exception, if other files instantiate generics from this --
23 -- unit, or you link this unit with other files to produce an executable, --
24 -- this unit does not by itself cause the resulting executable to be --
25 -- covered by the GNU General Public License. This exception does not --
26 -- however invalidate any other reasons why the executable file might be --
27 -- covered by the GNU Public License. --
28 -- --
29 -- GNAT was originally developed by the GNAT team at New York University. --
30 -- Extensive contributions were provided by Ada Core Technologies Inc. --
31 -- --
32 ------------------------------------------------------------------------------
34 -- This package provides subprogram implementations of stream attributes for
35 -- the following types:
36 -- Ada.String
37 -- Ada.Wide_String
38 -- Ada.Wide_Wide_String
40 -- The compiler will generate references to the subprograms in this package
41 -- when expanding stream attributes for the above mentioned types. Example:
43 -- String'Output (Some_Stream, Some_String);
45 -- will be expanded into:
47 -- String_Output (Some_Stream, Some_String);
49 pragma Warnings (Off);
50 pragma Compiler_Unit;
51 pragma Warnings (On);
53 with Ada.Streams;
55 package System.Strings.Stream_Ops is
57 ------------------------------
58 -- String stream operations --
59 ------------------------------
61 function String_Input
62 (Strm : access Ada.Streams.Root_Stream_Type'Class)
63 return String;
65 procedure String_Output
66 (Strm : access Ada.Streams.Root_Stream_Type'Class;
67 Item : String);
69 procedure String_Read
70 (Strm : access Ada.Streams.Root_Stream_Type'Class;
71 Item : out String);
73 procedure String_Write
74 (Strm : access Ada.Streams.Root_Stream_Type'Class;
75 Item : String);
77 -----------------------------------
78 -- Wide_String stream operations --
79 -----------------------------------
81 function Wide_String_Input
82 (Strm : access Ada.Streams.Root_Stream_Type'Class)
83 return Wide_String;
85 procedure Wide_String_Output
86 (Strm : access Ada.Streams.Root_Stream_Type'Class;
87 Item : Wide_String);
89 procedure Wide_String_Read
90 (Strm : access Ada.Streams.Root_Stream_Type'Class;
91 Item : out Wide_String);
93 procedure Wide_String_Write
94 (Strm : access Ada.Streams.Root_Stream_Type'Class;
95 Item : Wide_String);
97 ----------------------------------------
98 -- Wide_Wide_String stream operations --
99 ----------------------------------------
101 function Wide_Wide_String_Input
102 (Strm : access Ada.Streams.Root_Stream_Type'Class)
103 return Wide_Wide_String;
105 procedure Wide_Wide_String_Output
106 (Strm : access Ada.Streams.Root_Stream_Type'Class;
107 Item : Wide_Wide_String);
109 procedure Wide_Wide_String_Read
110 (Strm : access Ada.Streams.Root_Stream_Type'Class;
111 Item : out Wide_Wide_String);
113 procedure Wide_Wide_String_Write
114 (Strm : access Ada.Streams.Root_Stream_Type'Class;
115 Item : Wide_Wide_String);
117 end System.Strings.Stream_Ops;