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

Fix javadoc info generator array init printing #2845

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

SirYwell
Copy link
Contributor

@SirYwell SirYwell commented Sep 4, 2024

Printing of array initializers in the javadoc info generator was wrong:
wrong0
(multiple dimension expressions are comma-separated in the last [])

wrong1
(dimension expressions are generally moved into the last [])

The problem stems from how the full expression is a combination of type information and dimension expressions. This patch doesn't use the generic type printing code but instead a mix of printing dimension expressions and type information.

Note

I initially wanted to include annotations on the dimensions too, but I noticed that IntelliJ generally seems to attach annotations in the wrong order to the dimensions of the type. I assume this should be addressed separately first.

wrong2
(order of annotations is reversed - this problem remains as it is not caused by this part of the code)

One test needed to be adjusted because the formatting now wasn't stick together manually anymore. The visuals are equal though I think.

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

Successfully merging this pull request may close these issues.

2 participants