Use correct spans for format string errors
When encountering format string errors in a raw string, or regular
string literal with embedded newlines, account for the positional
change to use correct spans.
:drive by fix: 🚗
This commit is contained in:
@@ -763,7 +763,7 @@ pub fn expand_preparsed_format_args(ecx: &mut ExtCtxt,
|
||||
};
|
||||
|
||||
let fmt_str = &*fmt.node.0.as_str();
|
||||
let mut parser = parse::Parser::new(fmt_str);
|
||||
let mut parser = parse::Parser::new(fmt_str, fmt.node.1);
|
||||
let mut pieces = vec![];
|
||||
|
||||
while let Some(mut piece) = parser.next() {
|
||||
|
||||
Reference in New Issue
Block a user