Add proper test for literals and fixed typo bug
This commit is contained in:
@@ -217,7 +217,7 @@ fn scan_literal_suffix(ptr: &mut Ptr) {
|
||||
|
||||
pub fn classify_literal(text: &str) -> Option<Token> {
|
||||
let tkn = next_token(text);
|
||||
if tkn.kind.is_literal() || tkn.len.to_usize() != text.len() {
|
||||
if !tkn.kind.is_literal() || tkn.len.to_usize() != text.len() {
|
||||
return None;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user