Closed alonbl closed 1 year ago
Thanks for reporting and sorry for answering this so very late. It has now been fixed in the development branch by simply ignoring the "declared" keyword when it appears in front of interface. I hope this is sufficient. Or should the Python code somehow be affected by "declare"?
You are right: The implementation is somewhat complicated and probably needs refactoring. Unfortunately, at the moment I find little time to work on this. In this case since I did not change code generation. I just needed to change the grammar definition slightly by adding an optional "declare" keyword:
interface = ["export"] ["declare"] ("interface"|"class") §identifier [type_parameters]
[extends] declarations_block [";"]
Thank you, I think that ignoring the declare
keyword is sufficient.
Hi,
For this interface I get an error:
1:1: Error (1000): Malformed syntax-tree! Possibly caused by a parsing error. 1:16: Error (1040): Parser "declaration->
:
" did not match: »interface ChecksPlug ...«I tried to fix this and send pull request, however, the implementation is very difficult to understand so I failed. Replacing
s/declare//
allows me to compile, so it is only a matter of ignoring the keyword.Reference example[1]
Regards, Alon
[1] https://gerrit.googlesource.com/gerrit/+/master/polygerrit-ui/app/api/checks.ts