-
-
Notifications
You must be signed in to change notification settings - Fork 150
Open
Labels
bugSomething isn't workingSomething isn't working
Description
use logos::Logos;
#[derive(Logos, Debug, PartialEq)]
enum Token {
#[regex(r".*")]
BetweenParen,
}
fn main() {
let mut lex = Token::lexer("1234");
println!("{:#?}", lex.next().unwrap());
println!("{:#?}", lex.span());
}This can pass compilation now. Produce:
Ok(
BetweenParen,
)
0..4
If change the regex as .*4, it fails to match (tokenize).
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working