1
------------------------------------------------------------------------------
3
-- ASIS-for-GNAT IMPLEMENTATION COMPONENTS --
5
-- A S I S . T E X T . S E T _ G E T --
9
-- Copyright (c) 1995-1999, Free Software Foundation, Inc. --
11
-- ASIS-for-GNAT is free software; you can redistribute it and/or modify it --
12
-- under terms of the GNU General Public License as published by the Free --
13
-- Software Foundation; either version 2, or (at your option) any later --
14
-- version. ASIS-for-GNAT is distributed in the hope that it will be use- --
15
-- ful, but WITHOUT ANY WARRANTY; without even the implied warranty of MER- --
16
-- CHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General --
17
-- Public License for more details. You should have received a copy of the --
18
-- GNU General Public License distributed with ASIS-for-GNAT; see file --
19
-- COPYING. If not, write to the Free Software Foundation, 59 Temple Place --
20
-- - Suite 330, Boston, MA 02111-1307, USA. --
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. --
29
-- ASIS-for-GNAT was originally developed by the ASIS-for-GNAT team at the --
30
-- Software Engineering Laboratory of the Swiss Federal Institute of --
31
-- Technology (LGL-EPFL) in Lausanne, Switzerland, in cooperation with the --
32
-- Scientific Research Computer Center of Moscow State University (SRCC --
33
-- MSU), Russia, with funding partially provided by grants from the Swiss --
34
-- National Science Foundation and the Swiss Academy of Engineering --
35
-- Sciences. ASIS-for-GNAT is now maintained by Ada Core Technologies Inc --
36
-- (http://www.gnat.com). --
38
------------------------------------------------------------------------------
40
package Asis.Text.Set_Get is
46
function Line_Length (L : Line) return Character_Position;
47
function Line_Location (L : Line) return Source_Ptr;
48
-- when Line Lication is obtained, the tree is resetted if needed
50
function Valid (L : Line) return Boolean;
51
-- chechs, if the argument is valid, that is, if the Context
52
-- from which this line was obtained is still opened
54
function Debug_Image (The_Span : in Span) return String;
55
-- Produces the debug output for its argument
61
procedure Set_Line_Length (L : in out Line; N : Character_Position);
62
procedure Set_Line_Location (L : in out Line; S : Source_Ptr);
63
-- this procedure is intended to correct the Sloc field in
64
-- the first line from a line list covering a given Span.
65
-- This means, that all the fields of the Line to be corrected
66
-- have been already set as pointing to the beginning of
67
-- a given line. Together with setting the Sloc field, this
68
-- procedure adjust the Rel_Sloc field.
70
procedure Set_Lines (LList : in out Line_List; El : Element);
71
-- This procedure creates LList as a list of lines
72
-- accessable through El. It gets LList as a list
73
-- of Nil_Lines and makes the proper settings for
74
-- the components of each line, making them non-nil
75
-- It takes all the characteristics of these lines from El,
76
-- that is, from the tree on which El is based. This is
77
-- "tree-swapping-safe" procedure.
78
-- The only call to this procedure is in the third
79
-- Asis.Text.Lines function, which explicitly specifies
80
-- the bounds of the Line_List to be returned (that is, LList).
81
-- The caller makes all the checks needed to make sure, that
82
-- the compilation enclosing El really contains lines with numbers
83
-- LList'First and LList'Last
84
end Asis.Text.Set_Get;
b'\\ No newline at end of file'