|[Xpand] Strange behaviour of polymorphism when using stereotypes [message #665332]
||Thu, 14 April 2011 11:08
Registered: April 2011
i have encountered a strange problem when using polymorphism to resolve stereotypes applied to class properties or to association ends.
There is a stereotype "Generic", which is applicable to UML::Element.
This is the Xpand fragment in question:
«DEFINE typeArguments FOR xxx::Generic»
«DEFINE typeArguments FOR uml::Property»
/* ?! */
The /* ?! */ marker indeed appears in the generated source code. When trying to EXPAND something requiring a xxx:Generic instead, an exception is thrown indicating the lack of a matching definition, however:
No Definition 'something for uml::Property' found!
Explicitly checking for the "Generic" stereotype and its tagged values can be used instead. Did i miss something about Xpand polymorphism or is this a bug in the interpreter?
Any help appreciated.
Powered by FUDForum
. Page generated in 0.01883 seconds