8329099: Undocumented exception thrown by Instruction factory methods accepting Opcode

Reviewed-by: briangoetz
This commit is contained in:
Adam Sotona 2024-04-16 08:23:31 +00:00
parent def257727d
commit 97c180892b
17 changed files with 48 additions and 0 deletions

View file

@ -73,6 +73,8 @@ public sealed interface LoadInstruction extends Instruction
* @param op the opcode for the specific type of load instruction,
* which must be of kind {@link Opcode.Kind#LOAD}
* @param slot the local variable slot to load from
* @throws IllegalArgumentException if the opcode kind is not
* {@link Opcode.Kind#LOAD}.
*/
static LoadInstruction of(Opcode op, int slot) {
Util.checkKind(op, Opcode.Kind.LOAD);