未验证 提交 116c7ece 编写于 作者: P Phodal HUANG

add support for statement expression

上级 be0f3da9
......@@ -140,6 +140,19 @@ func (s *JavaRefactorListener) EnterExpressionList(ctx *ExpressionListContext) {
}
}
func (s *JavaRefactorListener) EnterStatement(ctx *StatementContext) {
for _, expression := range ctx.AllExpression() {
expText := expression.GetText()
if isUppercaseText(expText) {
startLine := ctx.GetStart().GetLine()
stopLine := ctx.GetStop().GetLine()
field := &JField{expText, node.Pkg, startLine, stopLine}
node.AddField(*field)
}
}
}
func (s *JavaRefactorListener) EnterCreatedName(ctx *CreatedNameContext) {
identifiers := ctx.AllIDENTIFIER()
for index, _ := range identifiers {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册