Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exception when parsing Enum with fields #1

Closed
kronar opened this issue May 21, 2015 · 2 comments
Closed

Exception when parsing Enum with fields #1

kronar opened this issue May 21, 2015 · 2 comments

Comments

@kronar
Copy link

kronar commented May 21, 2015

The parser throws exception when tries to parse enum with fields.
I've created small project that reproduces this issue.
https://github.com/kronar/qdox-bug

@jad7 jad7 mentioned this issue Jul 8, 2015
@rfscholte
Copy link
Collaborator

I've been searching through the Official Java Language Specification and it seems like the documentation isn't complete on this part: https://docs.oracle.com/javase/specs/jls/se8/html/jls-8.html#jls-EnumConstant describes how it should look like, but the arguments doesn't bring me to the methodInvocation. I'll try to get the draft for Java9, since it'll introduce modules. Hopefully they've added it, otherwise I'll ask them for the details.

@rpofuk
Copy link

rpofuk commented Sep 5, 2016

I also have same problem. Which part is not documented?

An enum constant may be followed by arguments, which are passed to the constructor of the enum when the constant is created during class initialization as described later in this section. The constructor to be invoked is chosen using the normal rules of overload resolution (§15.12.2). If the arguments are omitted, an empty argument list is assumed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants