aboutsummaryrefslogtreecommitdiffstats
path: root/iirs_walk.ads
diff options
context:
space:
mode:
authorgingold <gingold@b72b5c32-5f01-0410-b925-b5c7b92870f7>2006-10-03 03:31:50 +0000
committergingold <gingold@b72b5c32-5f01-0410-b925-b5c7b92870f7>2006-10-03 03:31:50 +0000
commit7a57404e5337453db969bf8f51cad9fa7f4c1913 (patch)
tree7798575d49b09892f190900b1f2fe05399528b53 /iirs_walk.ads
parent3b7b797401dbeb62f287314211c2e9373bf3ee28 (diff)
downloadghdl-7a57404e5337453db969bf8f51cad9fa7f4c1913.tar.gz
ghdl-7a57404e5337453db969bf8f51cad9fa7f4c1913.tar.bz2
ghdl-7a57404e5337453db969bf8f51cad9fa7f4c1913.zip
add iirs_walk
Diffstat (limited to 'iirs_walk.ads')
-rw-r--r--iirs_walk.ads27
1 files changed, 27 insertions, 0 deletions
diff --git a/iirs_walk.ads b/iirs_walk.ads
new file mode 100644
index 000000000..cfa6e9637
--- /dev/null
+++ b/iirs_walk.ads
@@ -0,0 +1,27 @@
+with Iirs; use Iirs;
+
+package Iirs_Walk is
+ type Walk_Status is
+ (
+ -- Continue to walk.
+ Walk_Continue,
+
+ -- Stop walking in the subtree, continue in the parent tree.
+ Walk_Up,
+
+ -- Abort the walk.
+ Walk_Abort);
+
+ type Walk_Cb is access function (El : Iir) return Walk_Status;
+
+ -- Walk on all elements of CHAIN.
+ function Walk_Chain (Chain : Iir; Cb : Walk_Cb) return Walk_Status;
+
+
+ function Walk_Assignment_Target (Target : Iir; Cb : Walk_Cb)
+ return Walk_Status;
+
+ -- Walk on all stmts and sub-stmts of CHAIN.
+ function Walk_Sequential_Stmt_Chain (Chain : Iir; Cb : Walk_Cb)
+ return Walk_Status;
+end Iirs_Walk;