mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 23:34:52 +02:00
8227922: DocTreeScanner does not dive into AttributeTree.getValue() and LiteralTree.getBody()
DocTreeScanner.visitAttribute and visitLiteral have to scan through the subnodes of AttributeTree and LiteralTree, respectivelly. Reviewed-by: vromero
This commit is contained in:
parent
da43cb5e46
commit
6e86f5b47b
6 changed files with 253 additions and 23 deletions
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2010, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
|
@ -49,10 +49,12 @@ import java.lang.reflect.*;
|
|||
import java.util.*;
|
||||
import javax.tools.*;
|
||||
|
||||
import com.sun.source.util.JavacTask;
|
||||
import com.sun.tools.javac.tree.JCTree;
|
||||
import com.sun.tools.javac.tree.JCTree.JCCompilationUnit;
|
||||
import com.sun.tools.javac.tree.TreeScanner;
|
||||
import com.sun.tools.javac.util.List;
|
||||
import com.sun.tools.javac.util.Pair;
|
||||
|
||||
public class JavacTreeScannerTest extends AbstractTreeScannerTest {
|
||||
/**
|
||||
|
@ -75,8 +77,8 @@ public class JavacTreeScannerTest extends AbstractTreeScannerTest {
|
|||
}
|
||||
}
|
||||
|
||||
int test(JCCompilationUnit tree) {
|
||||
return new ScanTester().test(tree);
|
||||
int test(Pair<JavacTask, JCCompilationUnit> taskAndTree) {
|
||||
return new ScanTester().test(taskAndTree.snd);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue