Skip to content

Commit e8cb83a

Browse files
committed
Add feature flag to reference docs for RFC 1623.
1 parent ba60af3 commit e8cb83a

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/doc/reference.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1356,14 +1356,15 @@ unsafe fn bump_levels_unsafe2() -> u32 {
13561356
Mutable statics have the same restrictions as normal statics, except that the
13571357
type of the value is not required to ascribe to `Sync`.
13581358

1359-
#### `'static` lifetime elision
1359+
#### `'static` lifetime elision [unstable]
13601360

13611361
Both constant and static declarations of reference types have *implicit*
13621362
`'static` lifetimes unless an explicit lifetime is specified. As such, the
13631363
constant declarations involving `'static` above may be written without the
13641364
lifetimes. Returning to our previous example:
13651365

13661366
```rust
1367+
#[feature(static_in_const)]
13671368
const BIT1: u32 = 1 << 0;
13681369
const BIT2: u32 = 1 << 1;
13691370

0 commit comments

Comments
 (0)