Yes, single underscore is restricted in Java the language but not as far as
I know at the JVM specification level.
I don't believe the leading underscore case is impacted at all by the
single case. My understanding is that Java is pathing the way for how
underscore is used in other languages,
Thanks for the feedback. I have also seen the convention used for "pseudo"
private methods, like you mention. And also for methods named so as not to
conflict with likely names already in source code.
I presume the Gradle codebase has names (or generates names) such as that
(since it triggered
As I recall the use of a single _ as variable name is restricted since JDK10
and will become an error in newer JDKs.
Does the use of a leading _ in an identifier has been discouraged as well in
newer JDKs? If so then we should do the same even of means breaking
compatibility.
Cheers
Andres
If it helps, I've seen some programmers with python background using the
underscore in Groovy for method declaration. It seems they use the
convention of the underscore prefix to note these methods aren't for public
consumption.
El jue, 11 feb 2021 a las 9:49, Paul King ()
escribió:
>
> Hi
Hi folks,
I would be interested in any thoughts about the following issue:
https://issues.apache.org/jira/browse/GROOVY-9936
TL;DR There is an edge case where Groovy 3 (Parrot) behavior now differs
from the old parser. Even though an argument could be made either way as to
which behavior is