# File json/lexer.rb, line 198 def nextto(regex) buf = "" while (true) c = self.nextchar() if !(regex =~ c).nil? || c == '\0' || c == '\n' || c == '\r' self.back() if (c != '\0') return(buf.chomp()) end buf += c end end