rouge
rouge copied to clipboard
Rust lexer does not support string continuation escapes
Name of the lexer Rust
Code sample A sample of the code that produces the bug.
const REQUEST: &[u8] = b"GET http://example.com/ HTTP/1.1\r\n\
Host: example.com\r\n\
Accept: */*\r\n\
\r\n";
It also helps if you can provide a link to a code sample on rouge.jneen.net.
Additional context
The REQUEST is a valid Rust string literal, as described in The Rust Reference, backslash at the end of line has special meaning in Rust.
One more example taken from The Rust Reference:
let a = "foobar";
let b = "foo\
bar";
let c = "foo\
bar";