mirror of
https://github.com/tiennm99/lombok.git
synced 2026-10-14 08:18:29 +00:00
compiling lombok with javac gives 1 warning. fixed this.
This commit is contained in:
1 parent
3cca3e018b
commit
f6eef8e50a
1 file changed
+7
-2
@@ -632,8 +632,7 @@ public class PrettyCommentsPrinter extends JCTree.Visitor {
|
||||
*/
|
||||
public void printUnit(JCCompilationUnit tree, JCClassDecl cdef) throws IOException {
|
||||
Object dc = getDocComments(tree);
|
||||
if (dc instanceof Map) this.docComments = (Map) dc;
|
||||
else if (dc instanceof DocCommentTable) this.docTable = (DocCommentTable) dc;
|
||||
loadDocCommentsTable(dc);
|
||||
printDocComment(tree);
|
||||
if (tree.pid != null) {
|
||||
consumeComments(tree.pos, tree);
|
||||
@@ -668,6 +667,12 @@ public class PrettyCommentsPrinter extends JCTree.Visitor {
|
||||
}
|
||||
}
|
||||
// where
|
||||
@SuppressWarnings("unchecked")
|
||||
private void loadDocCommentsTable(Object dc) {
|
||||
if (dc instanceof Map<?, ?>) this.docComments = (Map) dc;
|
||||
else if (dc instanceof DocCommentTable) this.docTable = (DocCommentTable) dc;
|
||||
}
|
||||
|
||||
boolean isUsed(final Symbol t, JCTree cdef) {
|
||||
class UsedVisitor extends TreeScanner {
|
||||
public void scan(JCTree tree) {
|
||||
|
||||
Reference in new issue
Block a user