From 94a0819fe3a0d679c3042a77bfe6a2afc505daea Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 17 Apr 2024 14:11:28 +0200 Subject: Adding upstream version 1.66.0+dfsg1. Signed-off-by: Daniel Baumann --- src/test/ui/check-static-values-constraints.stderr | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/test/ui/check-static-values-constraints.stderr') diff --git a/src/test/ui/check-static-values-constraints.stderr b/src/test/ui/check-static-values-constraints.stderr index b28cf0d6b..31939f7f6 100644 --- a/src/test/ui/check-static-values-constraints.stderr +++ b/src/test/ui/check-static-values-constraints.stderr @@ -1,4 +1,4 @@ -error[E0493]: destructors cannot be evaluated at compile-time +error[E0493]: destructor of `SafeStruct` cannot be evaluated at compile-time --> $DIR/check-static-values-constraints.rs:65:43 | LL | ..SafeStruct{field1: SafeEnum::Variant3(WithDtor), @@ -7,7 +7,7 @@ LL | | LL | | field2: SafeEnum::Variant1}}; | | ^- value is dropped here | |________________________________________________________________________________| - | statics cannot evaluate destructors + | the destructor for this type cannot be evaluated in statics error[E0010]: allocations are not allowed in statics --> $DIR/check-static-values-constraints.rs:79:33 @@ -22,6 +22,7 @@ LL | field2: SafeEnum::Variant4("str".to_string()) | ^^^^^^^^^^^ | = note: calls in statics are limited to constant functions, tuple structs and tuple variants + = note: consider wrapping this expression in `Lazy::new(|| ...)` from the `once_cell` crate: https://crates.io/crates/once_cell error[E0010]: allocations are not allowed in statics --> $DIR/check-static-values-constraints.rs:94:5 -- cgit v1.2.3