compiletest: Make a FIXME for escaped newlines less confusing

The old FIXME implies that we don't support escaped newlines, but in fact it
was added in the same patch that added support for escaped newlines.

The new FIXME makes it clear that we do currently support this, and that the
FIXME is for doing so in a less ad-hoc way.
This commit is contained in:
Zalathar 2024-12-28 14:23:12 +11:00
parent 3a4e82195e
commit f55736365a

View File

@ -1156,7 +1156,9 @@ fn parse_normalize_rule(raw_value: &str) -> Option<(String, String)> {
.captures(raw_value)?;
let regex = captures["regex"].to_owned();
let replacement = captures["replacement"].to_owned();
// FIXME: Support escaped new-line in strings.
// A `\n` sequence in the replacement becomes an actual newline.
// FIXME: Do unescaping in a less ad-hoc way, and perhaps support escaped
// backslashes and double-quotes.
let replacement = replacement.replace("\\n", "\n");
Some((regex, replacement))
}