[
https://issues.apache.org/jira/browse/LUCENE-10003?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17363412#comment-17363412
]
Dawid Weiss commented on LUCENE-10003:
--------------------------------------
Hi David. I've used plenty of those style-checking tools over the years and
none of them was really appealing to me until gjf came around. Maybe it's
precisely because of their philosophy to layout the code without changing its
semantic structure (the parse tree remains the same). The way I see it is that
tools like gjf relieve you from some mundane work (perhaps you can review
what's been formatted and adjust here and there but otherwise you don't have to
think about it much), while strict syntax checkers (pmd, error-prone) are often
just a pain, especially when the errors are false positives, require additional
ignore-marku, etc...
I don't have a strong opinion on the placement of brackets in array types. I
favor the "type"-style (String[]), mostly because you can say "String[].class"
and it makes a logical sense to me to treat it as a type everywhere too. We
could add this check to github PRs only (or even run the entire error prone
check github jobs). I really don't have any strong opinions about it.
> Disallow C-style array declarations
> -----------------------------------
>
> Key: LUCENE-10003
> URL: https://issues.apache.org/jira/browse/LUCENE-10003
> Project: Lucene - Core
> Issue Type: Improvement
> Reporter: David Smiley
> Assignee: David Smiley
> Priority: Minor
>
> The Google Java Format, that which we adhere to, disallows c-style array
> declarations: https://google.github.io/styleguide/javaguide.html#s4.8.3-arrays
> It's also known to "Error Prone":
> https://errorprone.info/bugpattern/MixedArrayDimensions
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]