Closed
Description
struct S {
#[cfg(untrue)]
a: int,
}
fn main() {
let s = S;
}
<anon>:7:13: 7:14 error: `S` is a structure name, but this expression uses it like a function name
<anon>:7 let s = S;
^
<anon>:7:13: 7:14 note: Did you mean to write: `S { /* fields */ }`?
<anon>:7 let s = S;
^
Here S { }
is suggested but it is also not allowed:
<anon>:7:14: 7:15 error: structure literal must either have at least one field or use functional structure update syntax
<anon>:7 let s = S{};
^