-
Notifications
You must be signed in to change notification settings - Fork 16
Conversation
| /self::\*\[@InternalType='CompilationUnit'\]//\*\[@InternalType='TypeDeclaration'\] | Declaration, Type | | ||
| /self::\*\[@InternalType='CompilationUnit'\]//\*\[@InternalType='TypeDeclarationStatement'\] | Statement, Declaration, Type, Incomplete | | ||
| /self::\*\[@InternalType='CompilationUnit'\]//\*\[@InternalType='MethodDeclaration'\] | Declaration, Function | | ||
| /self::\*\[@InternalType='CompilationUnit'\]//\*\[@InternalType='MethodDeclaration'\]/\*\[@internalRole\]\[@internalRole='name'\] | Function, Name | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These shouldn't have also Declaration
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good question. I'm not sure about it, but I've considered that the Declaration
role could be part of the parent node, while its children have different roles, in the same way that, in the case of the If
constructs, there's a parent If
, Statement
, while the children don't have the Statement
role anymore, even if they're part of the if statement (which is already noted using the If
role).
This makes it easier to differentiate the declaration node itself from its nodes, and that's why I think it may be better this way, but it's arguable.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, this is something I also tough about this, specially with some monster role lists for some nodes where I apply the Declaration and similar roles, we should probably decide what to do in this case and document it somewhere.
| /self::\*\[@InternalType='CompilationUnit'\]//\*\[@InternalType='Assignment'\]/self::\*\[@operator\]\[@operator='<<='\] | Bitwise, LeftShift | | ||
| /self::\*\[@InternalType='CompilationUnit'\]//\*\[@InternalType='Assignment'\]/self::\*\[@operator\]\[@operator='>>='\] | Bitwise, RightShift | | ||
| /self::\*\[@InternalType='CompilationUnit'\]//\*\[@InternalType='Assignment'\]/self::\*\[@operator\]\[@operator='>>>='\] | Bitwise, RightShift, Unsigned | | ||
| /self::\*\[@InternalType='CompilationUnit'\]//\*\[@InternalType='ArrayType'\] | Type, Primitive, List | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure Primitive
+List
is the same as an array. We probably need an Array role for consecutive access memory.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, I agree. I used List
because List
role is currently defined as a generic sequence (as it was in SDKv0)
No description provided.