mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 07:14:30 +02:00
8223803: j.l.c.MethodTypeDesc::insertParameterTypes doesn't control type of parameters
Reviewed-by: rriggs
This commit is contained in:
parent
092bb9e108
commit
917645194b
3 changed files with 37 additions and 2 deletions
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2018, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
|
@ -97,6 +97,11 @@ public interface ConstantDesc {
|
|||
* @throws ReflectiveOperationException if a class, method, or field
|
||||
* could not be reflectively resolved in the course of resolution
|
||||
* @throws LinkageError if a linkage error occurs
|
||||
*
|
||||
* @apiNote {@linkplain MethodTypeDesc} can represent method type descriptors
|
||||
* that are not representable by {@linkplain MethodType}, such as methods with
|
||||
* more than 255 parameter slots, so attempts to resolve these may result in errors.
|
||||
*
|
||||
* @jvms 5.4.3 Resolution
|
||||
* @jvms 5.4.4 Access Control
|
||||
*/
|
||||
|
|
|
@ -154,9 +154,11 @@ public interface MethodTypeDesc
|
|||
* @param paramTypes {@link ClassDesc}s describing the new parameter types
|
||||
* to insert
|
||||
* @return a {@linkplain MethodTypeDesc} describing the desired method type
|
||||
* @throws NullPointerException if any argument is {@code null}
|
||||
* @throws NullPointerException if any argument or its contents are {@code null}
|
||||
* @throws IndexOutOfBoundsException if {@code pos} is outside the closed
|
||||
* range {[0, parameterCount]}
|
||||
* @throws IllegalArgumentException if any element of {@code paramTypes}
|
||||
* is a {@link ClassDesc} for {@code void}
|
||||
*/
|
||||
MethodTypeDesc insertParameterTypes(int pos, ClassDesc... paramTypes);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue