SPT brackets pointing at 'wrong' AST node
To facilitate name binding a single
sin concrete syntax produces the following ASTNode( NaBLHelp( "s"{Use([Def("/ Module:debug#0 / Rule:enRoll#0 / Variable:s#0 /")])}, Use() ), None(), None(){Scope([(NablNsThisForAttr(), "/ anon 1 /")])} ){(Type(), ["Student"])}However running
test Type of parameter ref [[ [[s]]. ]] run debug to "Student"{_}yields
NaBLHelp("s"{Use(Result(168))},Use)pointing at the nested NaBLHelp constructorThis causes
run get-typeto fail intest Type of parameter ref [[ [[s]]. ]] run get-type to "Student"{_}(Note that
Submitted by Daco Harkes on 2 December 2014 at 10:47NaBLHelp(name, Use())andNaBLHelp(name, Def())are used to distinguish use and definition sites, but the outer constructor actually defines what is defined or used.)
Issue Log
On 2 December 2014 at 11:44 Daco Harkes commented:
I also have an example where the type is actually in the first child.
Debug gives
NaBLHelp(AttrRef("name"{Use(Result(174))}){(NablProp_multiplicity,Result(179)),(Type,Result(177))},Bind), whileAttrRefhas the type annotation.
Log in to post comments