-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
sql field comment semicolon with escape #4967
Conversation
private val logger: Logger = LoggerFactory.getLogger(getClass) | ||
|
||
def replaceComment(code: String): String = { | ||
try { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
better to add junit test case for this new function
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok,I do
while (matcher.find()) { | ||
val commentKeyword = matcher.group(1) | ||
val comment = matcher.group(2) | ||
val escapedComment = comment.replaceAll(";", "\\\\\\\\;") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
batter to add some comments to explain for using "\\\\" (eight )
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please review again.Thanks!
2.add code comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
Related issues/PRs
Related issues: #4966
Brief change log
Checklist