Index: xotcl/tests/forwardtest.xotcl =================================================================== diff -u -rf733c5df1b1a91a473d0e361ff206deaa4ecfa0a -r435b41481fb51bf000ebe736d8574fefbeec1710 --- xotcl/tests/forwardtest.xotcl (.../forwardtest.xotcl) (revision f733c5df1b1a91a473d0e361ff206deaa4ecfa0a) +++ xotcl/tests/forwardtest.xotcl (.../forwardtest.xotcl) (revision 435b41481fb51bf000ebe736d8574fefbeec1710) @@ -1,4 +1,4 @@ -# $Id: forwardtest.xotcl,v 1.3 2004/11/27 21:10:33 neumann Exp $ +# $Id: forwardtest.xotcl,v 1.4 2005/09/09 21:07:23 neumann Exp $ package require XOTcl namespace import -force xotcl::* package require xotcl::test @@ -274,3 +274,31 @@ ? [list set _ [NS create n4]] ::test::n4 NS filter "" } + +########################################### +# forward to expr + callstack +########################################### + +Object instforward expr -objscope + +Class C +C instproc xx {} {self} +C proc t {o expr} { + return [$o expr $expr] +} +C create c1 + +puts ==== +? {c1 expr {[self]}} ::c1 +? {c1 expr {[self] == "::c1"}} 1 +? {c1 expr {[my xx]}} ::c1 +? {c1 expr {[my info class]}} ::C +? {c1 expr {[my istype C]}} 1 +? {c1 expr {[my istype ::C]}} 1 + +? {C t ::c1 {[self]}} ::c1 +? {C t ::c1 {[self] == "::c1"}} 1 +? {C t ::c1 {[my xx]}} ::c1 +? {C t ::c1 {[my info class]}} ::C +? {C t ::c1 {[my istype C]}} 1 +? {C t ::c1 {[my istype ::C]}} 1 \ No newline at end of file