src/share/classes/com/sun/tools/javac/util/RichDiagnosticFormatter.java

changeset 1656
5da12e8a59ba
parent 1570
f91144b7da75
child 1678
c635a966ce84
equal deleted inserted replaced
1655:c6728c9addff 1656:5da12e8a59ba
507 JCDiagnostic d = diags.fragment("where.intersection", t, interfaces.prepend(supertype)); 507 JCDiagnostic d = diags.fragment("where.intersection", t, interfaces.prepend(supertype));
508 whereClauses.get(WhereClauseKind.INTERSECTION).put(t, d); 508 whereClauses.get(WhereClauseKind.INTERSECTION).put(t, d);
509 visit(supertype); 509 visit(supertype);
510 visit(interfaces); 510 visit(interfaces);
511 } 511 }
512 } else if (t.tsym.name.isEmpty()) {
513 //anon class
514 ClassType norm = (ClassType) t.tsym.type;
515 if (norm != null) {
516 if (norm.interfaces_field != null && norm.interfaces_field.nonEmpty()) {
517 visit(norm.interfaces_field.head);
518 } else {
519 visit(norm.supertype_field);
520 }
521 }
512 } 522 }
513 nameSimplifier.addUsage(t.tsym); 523 nameSimplifier.addUsage(t.tsym);
514 visit(t.getTypeArguments()); 524 visit(t.getTypeArguments());
515 if (t.getEnclosingType() != Type.noType) 525 if (t.getEnclosingType() != Type.noType)
516 visit(t.getEnclosingType()); 526 visit(t.getEnclosingType());
560 // </editor-fold> 570 // </editor-fold>
561 571
562 // <editor-fold defaultstate="collapsed" desc="symbol scanner"> 572 // <editor-fold defaultstate="collapsed" desc="symbol scanner">
563 /** 573 /**
564 * Preprocess a given symbol looking for (i) additional info (where clauses) to be 574 * Preprocess a given symbol looking for (i) additional info (where clauses) to be
565 * asdded to the main diagnostic (ii) names to be compacted 575 * added to the main diagnostic (ii) names to be compacted
566 */ 576 */
567 protected void preprocessSymbol(Symbol s) { 577 protected void preprocessSymbol(Symbol s) {
568 symbolPreprocessor.visit(s, null); 578 symbolPreprocessor.visit(s, null);
569 } 579 }
570 //where 580 //where

mercurial