[
https://issues.apache.org/jira/browse/GROOVY-11670?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17954903#comment-17954903
]
Saravanan commented on GROOVY-11670:
------------------------------------
Thank you [~emilles] , can you point me to this code fragment?
> Class names that start with lower case letters
> ----------------------------------------------
>
> Key: GROOVY-11670
> URL: https://issues.apache.org/jira/browse/GROOVY-11670
> Project: Groovy
> Issue Type: Improvement
> Components: parser-antlr4
> Affects Versions: 5.0.0-alpha-12, 4.0.26
> Reporter: Saravanan
> Priority: Minor
>
> Classes that start with a lower case name cause parsing errors. I am
> compiling this with @CompileStatic enabled in the compilerConfiguration
> {code:java}
> public class recordTesting {
> private recordTesting someFunction() {
> return null;
> }
> }{code}
> Unexpected input: ';\n\npublic class recordTesting {\n\n private static
> recordTesting someFunction(' @ line 5, column 46.
> tic recordTesting someFunction() {
> ^
> If none of the functions returned a type with a lower case first letter,
> things are fine. It looks like there is no issue with the lower class class
> definition, just the use of that type in a return value. Not sure if the
> CapitalizedIdentifier is an enforced groovy construct. Java allows this and
> groovy causes this to fail as well, preventing use of types defined in java
> {code:java}
> public class SomeOtherClass {
> private someClassDefinedInJava someFunction() {
> }
> }{code}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)