From 2e927c34a68671d7f090cbfafe70e87cac21375a Mon Sep 17 00:00:00 2001 From: mescalinum Date: Fri, 14 Oct 2011 22:18:50 +0000 Subject: add tclpd-interp-info and fix an error svn path=/trunk/externals/loaders/tclpd/; revision=15601 --- examples/tclpd-interp-info.tcl | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 examples/tclpd-interp-info.tcl (limited to 'examples') diff --git a/examples/tclpd-interp-info.tcl b/examples/tclpd-interp-info.tcl new file mode 100644 index 0000000..29c1ca8 --- /dev/null +++ b/examples/tclpd-interp-info.tcl @@ -0,0 +1,21 @@ +package require Tclpd 0.2.3 +package require TclpdLib 0.19 + +# utilities for getting informations about tclpd's interpreter + +proc tclpd-interp-info::constructor {self} { +} + +proc tclpd-interp-info::0_bang {self} { + pd::post "-------- namespaces and procs: -------------" + set nss [linsert [namespace children ::] 0 ::] + foreach ns $nss { + pd::post " $ns" + set procs [info procs ${ns}::*] + foreach p $procs { + pd::post " $p" + } + } +} + +pd::class tclpd-interp-info -- cgit v1.2.1