mirror of
https://github.com/alibaba/druid.git
synced 2023-03-04 19:17:16 +00:00
improve ParameterizedOutputVisitor
This commit is contained in:
@@ -69,6 +69,8 @@ public class Lexer {
|
||||
private int varIndex = -1;
|
||||
|
||||
protected CommentHandler commentHandler;
|
||||
|
||||
protected boolean hasComment = false;
|
||||
|
||||
public Lexer(String input){
|
||||
this(input, true);
|
||||
@@ -747,6 +749,7 @@ public class Lexer {
|
||||
|
||||
stringVal = subString(mark, bufPos);
|
||||
token = Token.MULTI_LINE_COMMENT;
|
||||
hasComment = true;
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -777,6 +780,7 @@ public class Lexer {
|
||||
|
||||
stringVal = subString(mark + 1, bufPos);
|
||||
token = Token.LINE_COMMENT;
|
||||
hasComment = true;
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -1045,4 +1049,8 @@ public class Lexer {
|
||||
|
||||
boolean handle(Token lastToken, String comment);
|
||||
}
|
||||
|
||||
public boolean isHasComment() {
|
||||
return hasComment;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user