api support for comment double slash // (#201)

* add comment support

* add comment support

Co-authored-by: kim <xutao@xiaoheiban.cn>
This commit is contained in:
kingxt
2020-11-12 16:57:28 +08:00
committed by GitHub
parent e6df21e0d2
commit 7b4a5e3ec6
5 changed files with 79 additions and 12 deletions

View File

@@ -36,6 +36,10 @@ func isSpace(r rune) bool {
return r == ' ' || r == '\t'
}
func isSlash(r rune) bool {
return r == '/'
}
func isNewline(r rune) bool {
return r == '\n' || r == '\r'
}