Open
Description
tests/ui/frontmatter/multifrontmatter-2.rs:
---
---
//~^ ERROR: invalid preceding whitespace for frontmatter close
---
//~^ ERROR: expected item, found `-`
// FIXME(frontmatter): make this diagnostic better
---
#![feature(frontmatter)]
fn main() {}
I expected to see this happen: this should be a //@ check-pass
Instead, this happened: this is an ERROR
Meta
As of #140035 (I had missed this test in the review)
The RFC text says:
All content is ignored by rustc until the same number of dashes is found at the start of a line. The line must terminate by 0+ whitespace and then a newline.
So a line with spaces before a ---
should not require escapaing (more -
on open/close) but should work just fine.