aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteve Bennett <steveb@workware.net.au>2018-06-30 17:24:45 +1000
committerSteve Bennett <steveb@workware.net.au>2018-06-30 17:24:45 +1000
commit365d9342e8bd8417d52c9a70b790322f7159ed27 (patch)
tree3cef0d15dd6d69abb3507b750e0643ca48fd4d1e
parentd0c1c9c437d5e8af31e3abaacde64663e8eb68e5 (diff)
downloadjimtcl-365d9342e8bd8417d52c9a70b790322f7159ed27.zip
jimtcl-365d9342e8bd8417d52c9a70b790322f7159ed27.tar.gz
jimtcl-365d9342e8bd8417d52c9a70b790322f7159ed27.tar.bz2
oo: Fix 'methods' for superclasses
Methods inherited from a base class are created with alias, so they are not returned by 'info procs'. Need to use 'info commands' instead.
-rw-r--r--oo.tcl2
1 files changed, 1 insertions, 1 deletions
diff --git a/oo.tcl b/oo.tcl
index a05aa01..b6ad4a9 100644
--- a/oo.tcl
+++ b/oo.tcl
@@ -78,7 +78,7 @@ proc class {classname {baseclasses {}} classvars} {
proc "$classname classvars" {} classvars { return $classvars }
proc "$classname classname" {} classname { return $classname }
proc "$classname methods" {} classname {
- lsort [lmap p [info procs "$classname *"] {
+ lsort [lmap p [info commands "$classname *"] {
lindex [split $p " "] 1
}]
}