antlr4 icon indicating copy to clipboard operation
antlr4 copied to clipboard

Added an option to generate the context classes final.

Open lkishalmi opened this issue 2 years ago • 2 comments

Well, I was trying to test some Java 21 features, when it hit me that the generated Context classes are not final, so I can't simply just announce a sealed super class for them.

This is a trivial fix for the issue. Other languages could benefit from this final-ization as well, however I'm not good enough in them, to take that responsibility.

Might be a step for #4310

lkishalmi avatar Sep 18 '23 07:09 lkishalmi

@parrt Any chance to get this one reviewed?

lkishalmi avatar Mar 24 '24 14:03 lkishalmi

Hi @lkishalmi It sounds reasonable but my mind it has been elsewhere for a while and I just don't know the latest java stuff; I'm also sure how it should be broadcast across other targets. Sorry!

parrt avatar Mar 27 '24 17:03 parrt