diff --git a/decode_stream.go b/decode_stream.go index 9907505..561de91 100644 --- a/decode_stream.go +++ b/decode_stream.go @@ -85,11 +85,11 @@ func (s *stream) read() bool { func (s *stream) skipWhiteSpace() { LOOP: - c := s.char() - if isWhiteSpace[c] { + switch s.char() { + case ' ', '\n', '\t', '\r': s.cursor++ goto LOOP - } else if c == nul { + case nul: if s.read() { goto LOOP }