Move raw_identifiers check to the lexer.

This commit is contained in:
Lymia Aluysia
2018-03-18 11:21:38 -05:00
parent 7d5c29b9ea
commit d2e7953d13
2 changed files with 5 additions and 4 deletions

View File

@@ -1155,6 +1155,10 @@ impl<'a> StringReader<'a> {
&format!("`r#{}` is not currently supported.", ident.name)
).raise();
}
if is_raw_ident {
let span = self.mk_sp(raw_start, self.pos);
self.sess.raw_identifier_spans.borrow_mut().push(span);
}
token::Ident(ident, is_raw_ident)
}));
}