Skip to content

Commit 8f1a0af

Browse files
Unit-like structs doc: Add compile fail tag
1 parent 3c5001f commit 8f1a0af

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/doc/book/src/structs.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,7 @@ rather than positions.
255255

256256
You can define a `struct` with no members at all:
257257

258-
```rust
258+
```rust,compile_fail,E0423
259259
struct Electron {} // Use empty braces...
260260
struct Proton; // ...or just a semicolon.
261261

0 commit comments

Comments
 (0)