Skip to content

Commit 215f758

Browse files
committed
Install open-java-format 2.98.0.4, which ships the Migrate changes
2.98.0.4 is out on GitHub, Maven Central and the Gradle Plugin Portal, so the pages now install it. It carries the three output changes that Migrate listed as not yet in a release: the cast fix (openjavaformat/open-java-format#78), the switch expression on the declaration's line (openjavaformat/open-java-format#76) and the /*** banner that no longer counts as javadoc (openjavaformat/open-java-format#74). Each now says it applies since 2.98.0.4, and the corpus paragraph no longer calls them unreleased. The GitHub Action page keeps 2.98.0.3 as the default of the action's version input, because the action itself still defaults to it.
1 parent f53c161 commit 215f758

2 files changed

Lines changed: 10 additions & 11 deletions

File tree

‎docs/migrate.md‎

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -8,22 +8,21 @@ produces no formatting diff and needs no reformatting commit.
88

99
- Since 2.98.0.3: a long string is no longer split after an escaped backslash followed by `n`, as if
1010
that were a line break, and imports with comments between them are formatted rather than rejected.
11-
- Not yet in a release: a cast to a parameterized type at the end of a call chain is no longer split
11+
- Since 2.98.0.4: a cast to a parameterized type at the end of a call chain is no longer split
1212
inside its type, `(PrivilegedAction<` on one line and `String>)` on the next, when the chain is
1313
inlined but the type does not fit behind it. The call breaks its arguments one per line instead.
14-
- Not yet in a release: a switch expression that initializes a variable or a field starts on the line
15-
of the declaration, `int x = switch (y) {`, with its cases eight columns further left, the shape a
14+
- Since 2.98.0.4: a switch expression that initializes a variable or a field starts on the line of
15+
the declaration, `int x = switch (y) {`, with its cases eight columns further left, the shape a
1616
plain assignment already had. This is the one change of palantir-java-format 2.99.0, brought over.
17-
- Not yet in a release: a comment that opens with `/***`, such as a banner, no longer counts as
18-
javadoc, so a blank line between it and the declaration after it stays, as after any other block
19-
comment.
17+
- Since 2.98.0.4: a comment that opens with `/***`, such as a banner, no longer counts as javadoc,
18+
so a blank line between it and the declaration after it stays, as after any other block comment.
2019

2120
Checked on 341 source files, about 24,000 lines: palantir-java-format 2.98.0 and open-java-format
2221
2.98.0.2 give byte-identical output. On the JDK 21 sources, 2.98.0.3 reformats 5 of the files that
23-
2.98.0.2 leaves unchanged when run again, all because of the string fix. Of the three unreleased
24-
changes, the cast fix changes one statement, in `sun.rmi.transport.tcp.TCPTransport`; the switch
25-
change moves 57 declarations in 51 files; and the banner change keeps 70 blank lines in 43 files,
26-
every one of them present in the source.
22+
2.98.0.2 leaves unchanged when run again, all because of the string fix. In 2.98.0.4 the cast fix
23+
changes one statement, in `sun.rmi.transport.tcp.TCPTransport`; the switch change moves 57
24+
declarations in 51 files; and the banner change keeps 70 blank lines in 43 files, every one of them
25+
present in the source.
2726

2827
The Java packages are unchanged as well. Only the names in your build and your scripts change.
2928

‎zensical.toml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ toggle.name = "Switch to system preference"
105105
# plugin puts it in before the Markdown is rendered, so it lands in code blocks too. The key is not
106106
# extra.version: the theme reads that one as the switch for a version selector.
107107
[project.extra]
108-
ojf_version = "2.98.0.3"
108+
ojf_version = "2.98.0.4"
109109

110110
# Renders every page as a Jinja template, for {{ ojf_version }}. A misspelt variable or a stray {{
111111
# fails the build instead of leaving a gap or the raw text on the site.

0 commit comments

Comments
 (0)