Disable string highlight injection for macros changing string literals

This commit is contained in:
Lukas Wirth 2021-11-23 22:05:52 +01:00
parent ec07bb98f8
commit f3b25a6fc8
3 changed files with 31 additions and 29 deletions

View file

@ -10,9 +10,10 @@ use crate::{syntax_highlighting::highlights::Highlights, HlRange, HlTag};
pub(super) fn highlight_format_string(
stack: &mut Highlights,
string: &ast::String,
expanded_string: &ast::String,
range: TextRange,
) {
if is_format_string(string).is_none() {
if is_format_string(expanded_string).is_none() {
return;
}