On Wed, 21 Oct 2020 20:12:51 GMT, Chris Plummer <[email protected]> wrote:
> Do we have coding guidelines that say to indent them 8? old "official" guidelines don't tell much about it, @aioobe's guidelines don't special-case array initiation, so it is covered by: > A continuation line should be indented in one of the following four ways > Variant 1: With 8 extra spaces relative to the indentation of the previous > line. > Variant 2: With 8 extra spaces relative to the starting column of the wrapped > expression. > Variant 3: Aligned with previous sibling expression (as long as it is clear > that it’s a continuation line) > Variant 4: Aligned with previous method call in a chained expression. which will suggest that 8 is the right indent here. google's code-style says that "array initializer may _optionally_ be formatted as if it were a "block-like construct.", which would mean 4, but note "may" and "_optionally_". personally I'd prefer consistency here, but if you think it will make the lives of emacs-lovers miserable, although I'm sure you can configure emacs to treat array-init as line continuation, and not as a block, I can revert that. ------------- PR: https://git.openjdk.java.net/jdk/pull/689
