-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add info for virtual and override functions #2
Comments
This is now partially addressed with 0d9bf26 Will implement the override node in the coming days |
Awesome! Feel free to add me as a reviewer if you want feedback on some PR. |
Hey @GNSPS, I would like to give this a try. Do you have some pointers to give me? Is this something that can be done without changing the grammar? |
Hey @fvictorio! I was at ETHDenver and left my email pile up, sorry about that! Yes, it should work without changing the grammar. I would start by checking this out: And, more specifically the example of the virtual keyword here: |
Hey @GNSPS @fvictorio I tried putting in a fix for this a local fork but couldn't quite figure out how the codes work, particularly in the |
@nicholaspai that files are automatically generated by ANTLR, they are not meant to be read. I haven't worked a lot on the parser, but the way I go about this is:
|
@fvictorio it looks like there is already an
|
Yes, I think that's the case. I will open a PR with some failing tests. If @GNSPS is ok with the API proposed there, then that can be the base for working on this. |
See #9 |
FunctionDefinition
s nodes with thevirtual
oroverride
keywords cannot be distinguished from nodes that don't have if. In other words:and
are represented by the same node.
I don't know the best way to add this. For
virtual
, maybe just aisVirtual
property would be enough, and consistent with how it's being done (isConstructor
,isFallback
, etc.).For
override
, since this can have parameters, I think a (possibly null)override
oroverrideSpecifier
would work.The text was updated successfully, but these errors were encountered: