1 ------------------------------------------------------------------------------
3 -- GNAT COMPILER COMPONENTS --
9 -- Copyright (C) 1992-2002 Free Software Foundation, Inc. --
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. --
22 -- GNAT was originally developed by the GNAT team at New York University. --
23 -- Extensive contributions were provided by Ada Core Technologies Inc. --
25 ------------------------------------------------------------------------------
27 with Types
; use Types
;
30 -- This package provides printing routines for the abstract syntax tree
31 -- These routines are intended only for debugging use.
34 -- This routine is called from the GNAT main program to dump trees as
35 -- requested by debug options (including tree of Standard if requested).
37 procedure Print_Tree_Node
(N
: Node_Id
; Label
: String := "");
38 -- Prints a single tree node, without printing descendants. The Label
39 -- string is used to preface each line of the printed output.
41 procedure Print_Tree_List
(L
: List_Id
);
42 -- Prints a single node list, without printing the descendants of any
43 -- of the nodes in the list
45 procedure Print_Tree_Elist
(E
: Elist_Id
);
46 -- Prints a single node list, without printing the descendants of any
47 -- of the nodes in the list
49 procedure Print_Node_Subtree
(N
: Node_Id
);
50 -- Prints the subtree routed at a specified tree node, including all
51 -- referenced descendants.
53 procedure Print_List_Subtree
(L
: List_Id
);
54 -- Prints the subtree consisting of the given node list and all its
55 -- referenced descendants.
57 procedure Print_Elist_Subtree
(E
: Elist_Id
);
58 -- Prints the subtree consisting of the given element list and all its
59 -- referenced descendants.
61 procedure pe
(E
: Elist_Id
);
62 pragma Export
(Ada
, pe
);
63 -- Debugging procedure (to be called within gdb)
64 -- same as Print_Tree_Elist
66 procedure pl
(L
: List_Id
);
67 pragma Export
(Ada
, pl
);
68 -- Debugging procedure (to be called within gdb)
69 -- same as Print_Tree_List
71 procedure pn
(N
: Node_Id
);
72 pragma Export
(Ada
, pn
);
73 -- Debugging procedure (to be called within gdb)
74 -- same as Print_Tree_Node with Label = ""
76 procedure pt
(N
: Node_Id
);
77 pragma Export
(Ada
, pt
);
78 -- Debugging procedure (to be called within gdb)
79 -- same as Print_Node_Subtree