Skip to content

Commit

Permalink
<fix>: remove ASTReference impl in CompiledVisitor
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaoma20082008 committed Sep 14, 2021
1 parent 42eca55 commit 5efa30a
Showing 1 changed file with 1 addition and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -153,26 +153,7 @@ public String visit(ASTReference node, Object data) {
// 1. Variables
// 2. Properties
// 3. Methods
String s;
if (node.getFirstToken().equals(node.getLastToken())) {
s = node.getFirstToken().image.substring(1);
} else {
s = node.getFirstToken().image;
for (Token t = node.getFirstToken().next; t != node.getLastToken(); t = t.next) {
if (StringUtils.isNotBlank(t.image)) {
s = t.image;
break;
}
}
}
if (node.jjtGetParent() instanceof ASTprocess) {
// 最外层直接输出
s = " $output.write($context.get(\"" + s + "\"));\r\n";
} else {
// 其它命令包含的
s = "$context.get(\"" + s + "\")";
}
return s;
return null;
}

@Override
Expand Down

0 comments on commit 5efa30a

Please sign in to comment.