View · Search · Index
No registered users in community xowiki
in last 10 minutes

[Xotcl] Error or normal behavior?

From: Victor Mayevski <vitick_at_gmail.com>
Date: Tue, 7 Dec 2010 20:40:32 -0800

It came to my attention that [namespace import -force nx::*] is a
requirement and not an option, otherwise things don't work right.
Example:

nx::Class create C
C method init args {puts [self]; next}
C create c
#error, commands "self" and "next" do not exist, but if I first do
[namespace import -force nx::*], everything works fine.

This is not how I thought the namespaced commands should work. Is this
a feature or a bug? If not a bug, then it needs to be clearly
documented.