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

Re: [Xotcl] XOTcl behaviour

From: Gustaf Neumann <neumann_at_wu-wien.ac.at>
Date: Mon, 18 Sep 2006 12:27:54 +0200

Murr, Florian schrieb:
> Dear XOTcl team,
> with XOTcl1.4.0 and XOTcl1.5.0 I encountered the following behaviour:
>
This behavior is unchanged since many years.
> ------------------------------------------------------------------------
> Class X -parameter {
> {p {}}
> }
>
> # works fine
> X create x1 -p {a b c}
>
> # blows up!!
> X create x2 -p {-name a -xyz b}
>
whatever "blows up" means: XOTcl replys an error message telling that it
tries
to call a method named "name a -xyz b".

The serializer handles this situation by using

    X create x2 [list -p {-name a -xyz b}]

Alternatively, one can use with slightly changed semantics
(no parsing of argument contents)

    X create x2
    x2 p {-name a -xyz b}

-gustaf neumann