8278461: Use Executable.getSharedParameterTypes() instead of Executable.getParameterTypes() in trusted code
Reviewed-by: redestad
This commit is contained in:
parent
525b20fce0
commit
ece98d859d
@ -371,7 +371,7 @@ public final class Constructor<T> extends Executable {
|
||||
sb.append(getDeclaringClass().getTypeName());
|
||||
sb.append('(');
|
||||
StringJoiner sj = new StringJoiner(",");
|
||||
for (Class<?> parameterType : getParameterTypes()) {
|
||||
for (Class<?> parameterType : getSharedParameterTypes()) {
|
||||
sj.add(parameterType.getTypeName());
|
||||
}
|
||||
sb.append(sj);
|
||||
|
@ -431,7 +431,7 @@ public final class Method extends Executable {
|
||||
|
||||
String toShortSignature() {
|
||||
StringJoiner sj = new StringJoiner(",", getName() + "(", ")");
|
||||
for (Class<?> parameterType : getParameterTypes()) {
|
||||
for (Class<?> parameterType : getSharedParameterTypes()) {
|
||||
sj.add(parameterType.getTypeName());
|
||||
}
|
||||
return sj.toString();
|
||||
|
Loading…
Reference in New Issue
Block a user