-
Notifications
You must be signed in to change notification settings - Fork 548
Open
Description
It's never explained what 'static
actually means. Currently, the only definition of 'static
given is two examples of what could be 'static
. Namely:
- "Both constant and static declarations of reference types have implicit
'static
lifetimes unless an explicit lifetime is specified."reference/src/lifetime-elision.md
Line 185 in b3ce606
## `const` and `static` elision
reference/src/items/constant-items.md
Line 24 in b3ce606
Constants must be explicitly typed. The type must have a `'static` lifetime: any - "string literaly always have
'static
lifetime."Line 14 in b3ce606
Consider the following example: string literals always have `'static`
reference/src/expressions/literal-expr.md
Line 176 in b3ce606
That is, the type is `&'static str`.
The exact semantics of 'static
should be made clear.
Metadata
Metadata
Assignees
Labels
No labels