--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/code/Types.java Fri Sep 07 11:24:59 2018 +0200
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/code/Types.java Fri Sep 07 15:56:21 2018 +0100
@@ -5022,6 +5022,10 @@
this.types = types;
}
+ protected void reportIllegalSignature(Type t) {
+ throw new InvalidSignatureException(t);
+ }
+
/**
* Assemble signature of given type in string buffer.
*/
@@ -5056,7 +5060,7 @@
break;
case CLASS:
if (type.isCompound()) {
- throw new InvalidSignatureException(type);
+ reportIllegalSignature(type);
}
append('L');
assembleClassSig(type);
@@ -5101,7 +5105,7 @@
}
case TYPEVAR:
if (((TypeVar)type).isCaptured()) {
- throw new InvalidSignatureException(type);
+ reportIllegalSignature(type);
}
append('T');
append(type.tsym.name);