solidity-parser-antlr
solidity-parser-antlr copied to clipboard
type: simplify Visitor definition
The definition of Visitor interface is very long and error-prone that it might(or, have already) lost update with changes made on ASTNode. It's better to automatically generate at least some of the attribute of the Visitor interface if possible. Currently, I can't think of a solution yet. @Leeleo3x Maybe you have some idea?
It is true that maintaining the typings for a javascript library is tedious and error-prone. I don't know any good solution for this. Rewriting the whole project in Typescript could be a solution and you may want to check antlr4ts https://www.npmjs.com/package/antlr4ts.