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

8346773: Fix unmatched brackets in some misc files #22861

Closed
wants to merge 5 commits into from

Conversation

MaxXSoft
Copy link
Member

@MaxXSoft MaxXSoft commented Dec 23, 2024

This patch fixes unmatched brackets in some files, mostly in comments, docs and man pages.


Progress

  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue
  • Change must be properly reviewed (3 reviews required, with at least 3 Reviewers)

Issue

  • JDK-8346773: Fix unmatched brackets in some misc files (Enhancement - P4)

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk.git pull/22861/head:pull/22861
$ git checkout pull/22861

Update a local copy of the PR:
$ git checkout pull/22861
$ git pull https://git.openjdk.org/jdk.git pull/22861/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 22861

View PR using the GUI difftool:
$ git pr show -t 22861

Using diff file

Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/22861.diff

Using Webrev

Link to Webrev Comment

@bridgekeeper
Copy link

bridgekeeper bot commented Dec 23, 2024

👋 Welcome back qxing! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@openjdk
Copy link

openjdk bot commented Dec 23, 2024

@MaxXSoft This change now passes all automated pre-integration checks.

ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details.

After integration, the commit message for the final commit will be:

8346773: Fix unmatched brackets in some misc files

Reviewed-by: kbarrett, alanb, rriggs, dholmes, erikj, liach

You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed.

At the time when this comment was updated there had been 23 new commits pushed to the master branch:

  • 9393897: 8346260: Test "javax/swing/JOptionPane/bug4174551.java" failed because the font size of message "Hi 24" is not set to 24 in Nimbus LookAndFeel
  • e98f412: 8346922: TestVectorReinterpret.java fails without the rvv extension on RISCV fastdebug VM
  • ca5390c: 8346924: TestVectorizationNegativeScale.java fails without the rvv extension on RISCV fastdebug VM
  • 07c9f71: 8346921: Remove unused arg in markWord::must_be_preserved
  • 84e6432: 8346288: WB_IsIntrinsicAvailable fails if called with wrong compilation level
  • a77ed30: 8336412: sun.net.www.MimeTable has a few unused methods
  • e769b53: 8346193: CrashGCForDumpingJavaThread do not trigger expected crash build with clang17
  • a87bc7e: 8345374: Ubsan: runtime error: division by zero
  • d3abf01: 8346101: [JVMCI] Export jdk.internal.misc to jdk.graal.compiler
  • 24c5ff7: 8346871: Improve robustness of java/util/zip/EntryCount64k.java test
  • ... and 13 more: https://git.openjdk.org/jdk/compare/c1b868d27d955b5e219caf8f76e87e5edf4c92df...master

As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details.

As you do not have Committer status in this project an existing Committer must agree to sponsor your change. Possible candidates are the reviewers of this PR (@erikj79, @kimbarrett, @liach, @AlanBateman, @RogerRiggs, @dholmes-ora) but any other Committer may sponsor as well.

➡️ To flag this PR as ready for integration with the above commit message, type /integrate in a new comment. (Afterwards, your sponsor types /sponsor in a new comment to perform the integration).

@openjdk openjdk bot added the rfr Pull request is ready for review label Dec 23, 2024
@openjdk
Copy link

openjdk bot commented Dec 23, 2024

@MaxXSoft The following labels will be automatically applied to this pull request:

  • build
  • client
  • compiler
  • core-libs
  • hotspot
  • i18n
  • serviceability

When this pull request is ready to be reviewed, an "RFR" email will be sent to the corresponding mailing lists. If you would like to change these labels, use the /label pull request command.

@openjdk openjdk bot added serviceability serviceability-dev@openjdk.org build build-dev@openjdk.org hotspot hotspot-dev@openjdk.org client client-libs-dev@openjdk.org core-libs core-libs-dev@openjdk.org compiler compiler-dev@openjdk.org i18n i18n-dev@openjdk.org labels Dec 23, 2024
@mlbridge
Copy link

mlbridge bot commented Dec 23, 2024

Webrevs

Copy link
Member

@erikj79 erikj79 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can really only review the doc files and the Makefile.

@@ -172,7 +172,7 @@ Provide informative, but not too verbose error messages.
All GoogleTest asserts print compared expressions and their values, so
there is no need to have them in error messages. Asserts print only
compared values, they do not print any of interim variables, e.g.
`ASSERT_TRUE((val1 == val2 && isFail(foo(8)) || i == 18)` prints only
`ASSERT_TRUE(val1 == val2 && isFail(foo(8)) || i == 18)` prints only
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking at this expression, I believe the intention is this.

Suggested change
`ASSERT_TRUE(val1 == val2 && isFail(foo(8)) || i == 18)` prints only
`ASSERT_TRUE((val1 == val2 && isFail(foo(8))) || i == 18)` prints only

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the suggestion, updated.

@@ -1082,7 +1082,7 @@ Warnings: All cp values have U+FE0F characters removed. See /annotationsDerived/
<type key="calendar" type="indian">ಭಾರತೀಯ ರಾಷ್ಟ್ರೀಯ ಕ್ಯಾಲೆಂಡರ್</type>
<type key="calendar" type="islamic">ಇಸ್ಲಾಮಿಕ್ ಕ್ಯಾಲೆಂಡರ್</type>
<type key="calendar" type="islamic-civil">ಇಸ್ಲಾಮಿಕ್-ಸಿವಿಲ್ ಕ್ಯಾಲೆಂಡರ್</type>
<type key="calendar" type="islamic-rgsa" draft="contributed">ಇಸ್ಲಾಮಿಕ್‌ ಕ್ಯಾಲೆಂಡರ್‌ (ಸೌದಿ ಅರೇಬಿಯಾ, ಸೈಟಿಂಗ್‌)bia, sighting)</type>
<type key="calendar" type="islamic-rgsa" draft="contributed">ಇಸ್ಲಾಮಿಕ್‌ ಕ್ಯಾಲೆಂಡರ್‌ (ಸೌದಿ ಅರೇಬಿಯಾ, ಸೈಟಿಂಗ್‌)</type>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi, we would not modify the contents of upstream data from CLDR.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, I've reverted these changes in the latest commit.

Copy link

@kimbarrett kimbarrett left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I strongly suggest avoiding omnibus changes like this when possible (which it
is here). Just because it's all about one "kind" of change doesn't make it a
cohesive change. This is touching many distinct areas of the JDK, and several
different languages as well. That makes it harder to review and to manage the
review, because it is large and affects a wide range of areas, so may need
many reviewers. And the whole thing might get stalled by discussion of one
piece.

There is also no mention of what testing has been done for this PR. Some of
the changes are in executable code, and need to be tested.

I think that all of the files in make/data/cldr/common are from the Unicode
Consortium, and should not be modified here.

@@ -245,7 +245,7 @@ <h3 id="error-messages">Error messages</h3>
<p>All GoogleTest asserts print compared expressions and their values,
so there is no need to have them in error messages. Asserts print only
compared values, they do not print any of interim variables, e.g.
<code>ASSERT_TRUE((val1 == val2 &amp;&amp; isFail(foo(8)) || i == 18)</code>
<code>ASSERT_TRUE(val1 == val2 &amp;&amp; isFail(foo(8)) || i == 18)</code>

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file is generated from the .md file, and should not be edited directly.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated both .md and .html using make update-build-docs in the latest commit.

@@ -47,7 +47,7 @@ LIB_FILES = $(shell find $(TESTLIBRARY_DIR)/jdk/test/lib/ \
$(TESTLIBRARY_DIR)/jdk/test/lib/process \
$(TESTLIBRARY_DIR)/jdk/test/lib/util \
$(TESTLIBRARY_DIR)/jtreg \
-maxdepth 1 -name '*.java'))
-maxdepth 1 -name '*.java')

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder why this hasn't caused problems and been found long ago? Does make just drop that stray
close-paren?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've tested this by running make, and the previous Makefile reports an error like file test/lib/jtreg/SkippedException.java) not found. So this fix is necessary.

I also checked the git log, this change was introduced in #22420, not that long ago.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, apparently this is not run as part of tier 1-3, which I ran in my patch. I wonder how this test is run. And it means this patch needs to be backported to 24.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only this small piece would be appropriate for backport to 24. I suggest splitting this out into its own bug,
fixing it in isolation, and backporting that.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The purpose of this Makefile seems to be to build ctw.jar. So far as I can tell, nothing in the JDK uses that jar,
or invokes that Makefile. There are some tests for the ctw component in hotspot/jtreg/testlibrary_tests/ctw. I
think if you ran tier4 testing that you would hit those. Or you could use TEST=hotspot:hotspot_misc, or
specify that directory. But those tests don't appear to use that jar. So I think there isn't a test that touches
this Makefile.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This makefile is not used by jtreg tests. The ctw code is compiled with
@library /test/lib / /testlibrary/ctw/src
so jtreg compiled the ctw library files itself.
This makefile might be used for standalone build if needed.
Thanks for fixing this!

@@ -61,8 +61,6 @@
.landscapeArea { page: land; width: 1010px; page-break-before: always; }

@page { margin: 0.1in; }

}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this affect the behavior of the test this is part of?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reverted.

<?xml version="1.0" encoding="UTF-8"?>
<oscars xmlns:osc-results="http://www.fatdog.com/oscar-results"

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't tell whether anything was changed in this file other than the modification of all the end of
line indicators. I've no idea whether changing those is appropriate or not, but this file came from
a 3rd party, so might not be appropriate to change here.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 to all of that. This change is un-reviewable.

<?xml version="1.0" encoding="UTF-8"?>
<oscars xmlns:osc-results="http://www.fatdog.com/oscar-results"

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this change affect the behavior of the associated test(s)?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was also wondering how this was tested.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FYI, the way to test this is ..
cd test/jdk
jtreg sanity/client/SwingSet/src/TableDemoTest.java

I tried converting all ^M to \n in this file another repo and comparing with your patch but every line was different so I just can't review this.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For safety reasons I've restored this file as well as all the files in unit tests.

@kimbarrett
Copy link

That makes it harder to review and to manage the review, because it is large and affects a wide range of areas, so may need many reviewers.

And many of the appropriate reviewers might be unavailable for a while, since it's right before Christmas.

@prrace
Copy link
Contributor

prrace commented Dec 23, 2024

/reviewers 3 reviewer

@openjdk
Copy link

openjdk bot commented Dec 23, 2024

@prrace Only the author (@MaxXSoft) is allowed to issue the reviewer command.

@prrace
Copy link
Contributor

prrace commented Dec 23, 2024

That makes it harder to review and to manage the review, because it is large and affects a wide range of areas, so may need many reviewers.

And many of the appropriate reviewers might be unavailable for a while, since it's right before Christmas.

I think at the very least this needs multiple reviewers. Even 2 isn't enough considering it is so cross-area.
It went to 7 different mailing lists, so that should tell you something !

@erikj79
Copy link
Member

erikj79 commented Dec 24, 2024

/reviewers 2

@openjdk
Copy link

openjdk bot commented Dec 24, 2024

@erikj79
The total number of required reviews for this PR (including the jcheck configuration and the last /reviewers command) is now set to 2 (with at least 1 Reviewer, 1 Author).

Copy link
Member

@erikj79 erikj79 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've reviewed doc/hotspot-unit-tests.* and the Makefile.

Copy link
Member

@liach liach left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the ctw fix.

/reviewers 3 reviewer

@@ -47,7 +47,7 @@ LIB_FILES = $(shell find $(TESTLIBRARY_DIR)/jdk/test/lib/ \
$(TESTLIBRARY_DIR)/jdk/test/lib/process \
$(TESTLIBRARY_DIR)/jdk/test/lib/util \
$(TESTLIBRARY_DIR)/jtreg \
-maxdepth 1 -name '*.java'))
-maxdepth 1 -name '*.java')
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, apparently this is not run as part of tier 1-3, which I ran in my patch. I wonder how this test is run. And it means this patch needs to be backported to 24.

@openjdk openjdk bot added the ready Pull request is ready to be integrated label Dec 24, 2024
@openjdk
Copy link

openjdk bot commented Dec 24, 2024

@liach
The total number of required reviews for this PR (including the jcheck configuration and the last /reviewers command) is now set to 3 (with at least 3 Reviewers).

@openjdk openjdk bot removed the ready Pull request is ready to be integrated label Dec 24, 2024
Copy link

@kimbarrett kimbarrett left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The fix for the ctw Makefile should not be included in this PR. It's a bug, and needs
to be fixed separately and backported to 24 to fix the introduction there via the
backport of JDK-8334733 from 25 to 24, without dragging the rest of this back to 24.

@MaxXSoft
Copy link
Member Author

@kimbarrett @liach Thanks for your suggestions!

I've moved the fix for the CTW Makefile to a separate pull request: #22878, please check it.

Copy link

@kimbarrett kimbarrett left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good.

@AlanBateman
Copy link
Contributor

/label remove i18n
/label remove client

@openjdk openjdk bot removed the i18n i18n-dev@openjdk.org label Dec 26, 2024
@openjdk
Copy link

openjdk bot commented Dec 26, 2024

@AlanBateman
The i18n label was successfully removed.

@openjdk openjdk bot removed the client client-libs-dev@openjdk.org label Dec 26, 2024
@openjdk
Copy link

openjdk bot commented Dec 26, 2024

@AlanBateman
The client label was successfully removed.

Copy link
Contributor

@AlanBateman AlanBateman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The title on the JBS issue is a mis-leading as it's now about man pages, docs, and a comment. Looks okay.

@MaxXSoft MaxXSoft changed the title 8346773: Fix unmatched brackets in source files 8346773: Fix unmatched brackets in some misc files Dec 26, 2024
@MaxXSoft
Copy link
Member Author

@AlanBateman Thanks for the review! I updated the title of the JBS issue and this PR.

@openjdk openjdk bot added the ready Pull request is ready to be integrated label Jan 2, 2025
@MaxXSoft
Copy link
Member Author

MaxXSoft commented Jan 3, 2025

Thank you all for your suggestions and reviews!

/integrate

@openjdk openjdk bot added the sponsor Pull request is ready to be sponsored label Jan 3, 2025
@openjdk
Copy link

openjdk bot commented Jan 3, 2025

@MaxXSoft
Your change (at version 7f85c5e) is now ready to be sponsored by a Committer.

Copy link
Member

@dholmes-ora dholmes-ora left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM2.

@dholmes-ora
Copy link
Member

/sponsor

@openjdk
Copy link

openjdk bot commented Jan 6, 2025

Going to push as commit f1d85ab.
Since your change was applied there have been 23 commits pushed to the master branch:

  • 9393897: 8346260: Test "javax/swing/JOptionPane/bug4174551.java" failed because the font size of message "Hi 24" is not set to 24 in Nimbus LookAndFeel
  • e98f412: 8346922: TestVectorReinterpret.java fails without the rvv extension on RISCV fastdebug VM
  • ca5390c: 8346924: TestVectorizationNegativeScale.java fails without the rvv extension on RISCV fastdebug VM
  • 07c9f71: 8346921: Remove unused arg in markWord::must_be_preserved
  • 84e6432: 8346288: WB_IsIntrinsicAvailable fails if called with wrong compilation level
  • a77ed30: 8336412: sun.net.www.MimeTable has a few unused methods
  • e769b53: 8346193: CrashGCForDumpingJavaThread do not trigger expected crash build with clang17
  • a87bc7e: 8345374: Ubsan: runtime error: division by zero
  • d3abf01: 8346101: [JVMCI] Export jdk.internal.misc to jdk.graal.compiler
  • 24c5ff7: 8346871: Improve robustness of java/util/zip/EntryCount64k.java test
  • ... and 13 more: https://git.openjdk.org/jdk/compare/c1b868d27d955b5e219caf8f76e87e5edf4c92df...master

Your commit was automatically rebased without conflicts.

@openjdk openjdk bot added the integrated Pull request has been integrated label Jan 6, 2025
@openjdk openjdk bot closed this Jan 6, 2025
@openjdk openjdk bot removed ready Pull request is ready to be integrated rfr Pull request is ready for review sponsor Pull request is ready to be sponsored labels Jan 6, 2025
@openjdk
Copy link

openjdk bot commented Jan 6, 2025

@dholmes-ora @MaxXSoft Pushed as commit f1d85ab.

💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored.

@MaxXSoft MaxXSoft deleted the fix-unmatched-brackets branch January 6, 2025 06:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build build-dev@openjdk.org compiler compiler-dev@openjdk.org core-libs core-libs-dev@openjdk.org hotspot hotspot-dev@openjdk.org integrated Pull request has been integrated serviceability serviceability-dev@openjdk.org
Development

Successfully merging this pull request may close these issues.

10 participants