6922300: [308] populate the reference_info for type annotations targeting primitive class literals
Co-authored-by: Michael Ernst <mernst@cs.washington.edu> Reviewed-by: darcy, jjg
This commit is contained in:
parent
3485352c43
commit
9452aaa027
@ -2158,6 +2158,11 @@ public class Gen extends JCTree.Visitor {
|
||||
code.emitop2(ldc2, makeRef(tree.pos(), tree.selected.type));
|
||||
result = items.makeStackItem(pt);
|
||||
return;
|
||||
} else if (tree.name == names.TYPE) {
|
||||
// Set the annotation positions for primitive class literals
|
||||
// (e.g. int.class) which have been converted to TYPE field
|
||||
// access on the corresponding boxed type (e.g. Integer.TYPE).
|
||||
setTypeAnnotationPositions(tree.pos);
|
||||
}
|
||||
|
||||
Symbol ssym = TreeInfo.symbol(tree.selected);
|
||||
|
Loading…
Reference in New Issue
Block a user