Closed
Description
The code
fn main() {
let x = 0;
let y = x.max(1) //!foo
.min(2);
}
I get this error:
error: expected one of `.`, `;`, `?`, or an operator, found `//!foo`
--> src/main.rs:3:22
|
3 | let y = x.max(1) //!foo
| ^^^^^^ expected one of `.`, `;`, `?`, or an operator here
Probably something like:
error: expected outer doc comment
--> src/main.rs:3:16
|
3 | let y = x; //!foo
| ^^^^^^
|
= note: inner doc comments like this (starting with `//!` or `/*!`) can only appear before items
is more helpful because at least you can understand what's wrong (especially when you don't know inner doc comments).