On Fri, 18 Jun 2021 14:35:42 GMT, Maurizio Cimadamore <mcimadam...@openjdk.org> wrote:
>> Jan Lahoda has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Updating javadoc, code and tests as suggested. > > src/java.base/share/classes/java/lang/runtime/SwitchBootstraps.java line 175: > >> 173: * Bootstrap method for linking an {@code invokedynamic} call site >> that >> 174: * implements a {@code switch} on a target of an enum type. The >> static >> 175: * arguments are an array of case labels which must be non-null and >> of type > > This sentence can still be improved and made cleared. Example: > >> The static arguments are used to encode the case labels associated to the >> `switch` construct, where each label can be encoded as a `String` (e.g. to >> represent an enum constant), or, alternatively, as a `Class` (e.g. to >> represent a type test pattern whose type is an enum type). Thanks. I've updated the javadoc and improved the validation a little, checking the `Class` objects provided. ------------- PR: https://git.openjdk.java.net/jdk17/pull/81