On Tue, 27 Jun 2023 13:10:40 GMT, Daniel Fuchs <dfu...@openjdk.org> wrote:
> It's a bit smelly to have a public static field of type array. Static > analysers are likely to flag this. It would be better to make the field > private and have a public static method that returns DIGITS.clone() - then > each class that needs it (and if I'm not mistaken there are only two) could > encapsulate its own private copy. I don't think this is a problem. If users can access JDK internal packages, it can do many things. For example, through `JavaLangAccess::getEnumConstantsShared`, an array shared within JDK can be obtained. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/14578#discussion_r1243750135