[Xotcl] XOTcl1.5.6 and Tcl8.5b1
Gustaf Neumann
neumann at wu-wien.ac.at
Mon Oct 29 15:30:01 CET 2007
You are right,
there seems to be a problem with default values for nonpos args
in tcl 8.5 after the var reform changes. i will look into the problem
today evening or tomorrow morning.
best regards
-gustaf neumann
Murr, Florian schrieb:
> Dear XOTcl-guys!
> I tried to upgrade from Tcl8.4+XOTcl1.5.3 (all my projects worked fine
> here!) to Tcl8.5b1, but my projects won't run due to some XOTcl
> problems.
> The following snippet is extracted from my project and I tested it with
> XOTcl1.5.5 (from WinTclTk) and XOTcl1.5.6 from ActiveState-Teacup.
> But both failed with the same error message.
> My guess: Non-positional Arguments don't work!
>
> #
> ************************************************************************
> *****
> # The script:
>
>
> Class X
> X instproc ListOfStringsOption {{-default {}} {-cb {}} name} {
> if {$cb eq {}} { set cb "::set ::$name " } ;# global variable
> eval $cb \$default
> }
> ::X create x1
> ::x1 ListOfStringsOption uu
>
>
> #
> ************************************************************************
> *****
> # Error message:
> can't read "default": no such variable
> while executing
> "::set ::uu $default"
> ("eval" body line 1)
> invoked from within
> "eval $cb \$default"
> (procedure "ListOfStringsOption" line 5)
> ::x1 ::X->ListOfStringsOption
> invoked from within
> "::x1 ListOfStringsOption uu"
>
>
> _______________________________________________
> Xotcl mailing list
> Xotcl at alice.wu-wien.ac.at
> http://alice.wu-wien.ac.at/mailman/listinfo/xotcl
>
More information about the Xotcl
mailing list