Skip to content

Commit dbfc8c5

Browse files
Update diagnostics.rs
1 parent 42c5c98 commit dbfc8c5

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/librustc/diagnostics.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -177,9 +177,9 @@ the heap at runtime, and therefore cannot be done at compile time.
177177
"##,
178178

179179
E0011: r##"
180-
Using a user-defined operator on const/static variable is restricted to what
181-
can be evaluated at compile-time. Using an user-defined operator could call a
182-
user-defined function, which is not allowed.
180+
Initializers for constants and statics are evaluated at compile time.
181+
User-defined operators rely on user-defined functions, which cannot be evaluated
182+
at compile time.
183183
184184
Bad example:
185185

0 commit comments

Comments
 (0)