1 Commits

Author SHA1 Message Date
1bb8ab5e9b fixed IsWhitespace function consideres tabs as whitespace 2023-06-30 19:16:25 +02:00

View File

@ -12,8 +12,12 @@ func IsSpace(rn rune) bool {
return rn == ' ' return rn == ' '
} }
func IsTab(rn rune) bool {
return rn == '\t'
}
func IsWhitespace(rn rune) bool { func IsWhitespace(rn rune) bool {
return IsSpace(rn) || IsNewLine(rn) return IsSpace(rn) || IsTab(rn) || IsNewLine(rn)
} }
func And(f ...RuneFunc) RuneFunc { func And(f ...RuneFunc) RuneFunc {