This PR includes two changes. First, `Locale.getDisplayScript(Locale)` incorrectly copies the return description of its sibling method `Locale.getDisplayScript()`. It is corrected to describe the actual contract.
Second, the `getDisplayXXX` methods are updated to better distinguish the `Locale` from which the methods are invoked on versus the `Locale` which is used for localization of the output. An example of this issue is the following, `Locale.getDisplayCountry()` states it returns "The name of the country appropriate to the locale." `Locale.String getDisplayCountry(Locale inLocale)` states it returns "The name of the country appropriate to the given locale." In the no-arg method, "locale" refers to `this`, while in the 1-arg method, "locale" is `inLocale`. It would be more clear if the methods consistently referred to the same "locale". i.e., either the one doing the localizing, or the one from which the methods are invoked on. ------------- Commit messages: - Clarify 'locale' in get display methods Changes: https://git.openjdk.org/jdk/pull/30590/files Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=30590&range=00 Issue: https://bugs.openjdk.org/browse/JDK-8381681 Stats: 22 lines in 1 file changed: 4 ins; 1 del; 17 mod Patch: https://git.openjdk.org/jdk/pull/30590.diff Fetch: git fetch https://git.openjdk.org/jdk.git pull/30590/head:pull/30590 PR: https://git.openjdk.org/jdk/pull/30590
