quickscript 0.5.5

A quick programming language with a compiler implemented in Rust.
Documentation
use crate::tokenizer::consumer::Cursor;

use super::ttype::TokenType;

impl TokenType {
    pub fn read_string(buf: &mut Cursor<char>) -> TokenType {
        let mut s = Vec::new();

        while let Some(ch) = buf.next() {
            if ch == '"' && s.last() != Some(&'\\') {
                break;
            }

            s.push(ch);
        }

        TokenType::String(s)
    }
}