aboutsummaryrefslogtreecommitdiffstats
path: root/src/psl
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2016-02-07 07:29:38 +0100
committerTristan Gingold <tgingold@free.fr>2016-02-09 20:25:02 +0100
commit5ddefe0ca2f02afdb7a10717b9feb77a42fbc901 (patch)
tree6203c06742e2e00b75ccdc40b56945c5305c738a /src/psl
parentf5130442c175e7308e26b092dcebd0c6901e4881 (diff)
downloadghdl-5ddefe0ca2f02afdb7a10717b9feb77a42fbc901.tar.gz
ghdl-5ddefe0ca2f02afdb7a10717b9feb77a42fbc901.tar.bz2
ghdl-5ddefe0ca2f02afdb7a10717b9feb77a42fbc901.zip
Improve mixed dump of PSL and VHDL nodes.
Diffstat (limited to 'src/psl')
-rw-r--r--src/psl/psl-dump_tree.adb21
-rw-r--r--src/psl/psl-dump_tree.ads5
2 files changed, 8 insertions, 18 deletions
diff --git a/src/psl/psl-dump_tree.adb b/src/psl/psl-dump_tree.adb
index 93a407138..700c120d3 100644
--- a/src/psl/psl-dump_tree.adb
+++ b/src/psl/psl-dump_tree.adb
@@ -65,13 +65,14 @@ package body PSL.Dump_Tree is
end if;
end Image_Boolean;
- procedure Disp_HDL_Node (Val : HDL_Node)
- is
+ procedure Disp_HDL_Node
+ (Val : HDL_Node; Indent : Natural; Depth : Natural) is
begin
if Dump_Hdl_Node /= null then
- Dump_Hdl_Node.all (Val);
+ Dump_Hdl_Node.all (Val, Indent, Depth);
else
Disp_Int32 (Val);
+ New_Line;
end if;
end Disp_HDL_Node;
@@ -143,8 +144,6 @@ package body PSL.Dump_Tree is
New_Line;
end Disp_Header;
- procedure Disp_Tree (N : Node; Indent : Natural; Depth : Natural);
-
procedure Disp_Chain (Tree_Chain: Node; Indent: Natural; Depth : Natural)
is
El: Node;
@@ -206,8 +205,7 @@ package body PSL.Dump_Tree is
when Type_Name_Id =>
Put_Line (Name_Table.Image (Get_Name_Id (N, F)));
when Type_HDL_Node =>
- Disp_HDL_Node (Get_HDL_Node (N, F));
- New_Line;
+ Disp_HDL_Node (Get_HDL_Node (N, F), Sub_Indent, Depth - 1);
when Type_NFA =>
Disp_NFA (Get_NFA (N, F));
New_Line;
@@ -219,13 +217,4 @@ package body PSL.Dump_Tree is
end;
end Disp_Tree;
- procedure Dump_Tree (N : Node; Full : Boolean := False) is
- begin
- if Full then
- Disp_Tree (N, 0, 20);
- else
- Disp_Tree (N, 0, 0);
- end if;
- end Dump_Tree;
-
end PSL.Dump_Tree;
diff --git a/src/psl/psl-dump_tree.ads b/src/psl/psl-dump_tree.ads
index bf412d0dd..0b849ac54 100644
--- a/src/psl/psl-dump_tree.ads
+++ b/src/psl/psl-dump_tree.ads
@@ -19,9 +19,10 @@
with PSL.Nodes; use PSL.Nodes;
package PSL.Dump_Tree is
- procedure Dump_Tree (N : Node; Full : Boolean := False);
+ procedure Disp_Tree (N : Node; Indent : Natural; Depth : Natural);
-- Procedure to dump an HDL node.
- type Dump_Hdl_Node_Acc is access procedure (N : HDL_Node);
+ type Dump_Hdl_Node_Acc is
+ access procedure (N : HDL_Node; Indent : Natural; Depth : Natural);
Dump_Hdl_Node : Dump_Hdl_Node_Acc := null;
end PSL.Dump_Tree;