fn consume_while<F: Fn(char) -> bool>(&mut self, test: F) -> String {
        let mut result = String::new();
        while !self.eof() && test(self.next_char()) {
            result.push(self.consume_char());
        }
        result
    }
// skip characters until test fn returns true
skip characters until test fn returns true
skip characters until test fn returns true
fn consume_while<F: Fn(char) -> bool>(&mut self, test: F) -> String {
        let mut result = String::new();
        while !self.eof() && test(self.next_char()) {
            result.push(self.consume_char());
        }
        result
    }
fn consume_while < F : Fn ( char ) -> bool > ( & mut self , test : F ) -> String { let mut result = String :: new ( ) ; while ! self . eof ( ) && test ( self . next_char ( ) ) { result . push ( self . consume_char ( ) ) ; } result }
skip characters until test fn returns true
skip characters until test fn returns true
&mut self
test
F
&mut self
test
F