Tcl Source Code

Artifact [dfbc06a36e]
Login

Artifact dfbc06a36ef6c5cf0185997b9f344c24e7fe05c7:

Attachment "test.itcl" to ticket [1502988fff] added by tombert 2006-06-08 22:41:43.
#
package require Itcl
namespace import itcl::*

class base {
  public method printHeritage {}
}

class derrived {
  inherit base
}

body base::printHeritage {} {
  for {set i 1} { $i < 10000000 } { incr i} {
      puts "$i [uplevel [info heritage]]"
      #puts "$i [info heritage]"
  }
}

class derrrived {
  inherit derrived
  public method checkMemLeak {}
}


body derrrived::checkMemLeak {} {
  base inst
  inst printHeritage
}

derrrived inst
inst checkMemLeak