Closed loradd closed 1 month ago
I am currently working from the branch maintenance/kolasu15
. Is this correct? @ftomassetti
I am currently working from the branch maintenance/kolasu15. Is this correct? @ftomassetti
Yes, it is, thank you. We will then merge maintenance/kolasu15
into main
When instantiating a parser, a corresponding instantiator is used at the moment. In order to implement a custom one, we can implement the
KolasuParserInstantiator
interface and bind it in our starlasu-conf.yaml file.The current
KolasuParserInstantiator
can only be used with parsers extendingKolasuParser
and it would be nice to relax this constraint toASTParser
. For example, this would allow to use parser instantiators in the RPG parser project - where the main parser does not extendKolasuParser
.Using
ASTParser
instead ofKolasuParser
would still work as no methods or property specific of this last one is currently used. Indeed, we invoke theparse
method on the instantiated parser and this method is inherited fromASTParser
.A possible solution to avoid breaking existing instantiators could consist in introducing an
ASTParserInstantiator
interface and make theKolasuParserInstantiator
extend it.Also see: https://github.com/Strumenta/starlasu-tools/issues/106