Skip to content

Commit

Permalink
Improve diagnostics (#6929)
Browse files Browse the repository at this point in the history
  • Loading branch information
mernst authored Dec 17, 2024
1 parent f8f11f7 commit 976cf08
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2368,12 +2368,12 @@ public abstract void processCompoundAssignment(
private void visitLists(List<? extends Tree> javacTrees, List<? extends Node> javaParserNodes) {
if (javacTrees.size() != javaParserNodes.size()) {
throw new BugInCF(
"%s.visitLists(%s [size %d], %s [size %d])",
"%s.visitLists([sizes %d, %d] %s, %s)",
this.getClass().getCanonicalName(),
javacTrees,
javacTrees.size(),
javaParserNodes,
javaParserNodes.size());
javaParserNodes.size(),
javacTrees,
javaParserNodes);
}
Iterator<? extends Node> nodeIter = javaParserNodes.iterator();
for (Tree tree : javacTrees) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -740,7 +740,7 @@ protected void setParentChecker(SourceChecker parentChecker) {
*/
@SuppressWarnings("interning:assignment") // used in == tests
public void setRoot(CompilationUnitTree newRoot) {
this.currentRoot = newRoot;
currentRoot = newRoot;
visitor.setRoot(currentRoot);
if (parentChecker == null) {
// Only clear the path cache if this is the main checker.
Expand Down

0 comments on commit 976cf08

Please sign in to comment.