rust/tests/ui/statics
Matthias Krüger 088f6ab1c5
Rollup merge of #143092 - RalfJung:const-check-lifetime-ext, r=oli-obk
const checks for lifetime-extended temporaries: avoid 'top-level scope' terminology

This error recently got changed in https://github.com/rust-lang/rust/pull/140942 to use the terminology of "top-level scope", but after further discussion in https://github.com/rust-lang/reference/pull/1865 it seems the reference will not be using that terminology after all. So let's also remove it from the compiler again, and let's focus on what actually happens with these temporaries: their lifetime is extended until the end of the program.

r? ``@oli-obk`` ``@traviscross``
2025-06-27 22:13:06 +02:00
..
auxiliary Use non-2015 edition paths in tests that do not test for their resolution 2025-06-05 09:19:31 +02:00
check-immutable-mut-slices.rs const checks: avoid 'top-level scope' terminology 2025-06-27 17:03:48 +02:00
check-immutable-mut-slices.stderr const checks: avoid 'top-level scope' terminology 2025-06-27 17:03:48 +02:00
check-recursion-foreign.rs tests: remove //@ pretty-expanded usages 2024-11-26 02:50:48 +08:00
check-values-constraints.rs Note def descr in NonConstFunctionCall 2024-12-23 22:15:32 +00:00
check-values-constraints.stderr Note def descr in NonConstFunctionCall 2024-12-23 22:15:32 +00:00
const_generics.rs Stabilize const_refs_to_static 2024-09-26 13:21:15 +02:00
inner-static.rs Move some tests out of tests/ui 2025-05-03 17:22:52 +02:00
issue-14227.rs Use the informative error as the main const eval error message 2025-06-02 15:37:15 +00:00
issue-14227.stderr const-eval error: always say in which item the error occurred 2025-06-07 13:42:30 +02:00
issue-15261.rs Fix error message for static references or mutable references 2025-04-26 14:48:30 +09:00
issue-15261.stderr Fix error message for static references or mutable references 2025-04-26 14:48:30 +09:00
issue-17233.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-17718-static-sync.rs
issue-17718-static-sync.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-17718-static-unsafe-interior.rs tests: remove //@ pretty-expanded usages 2024-11-26 02:50:48 +08:00
issue-44373-2.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-44373.rs
issue-44373.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-91050-1.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-91050-2.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
missing_lifetime.rs Avoid follow-up errors and ICEs after missing lifetime errors on data structures 2024-07-11 11:00:15 +00:00
missing_lifetime.stderr Make missing lifetime suggestion verbose 2025-06-24 18:59:42 +00:00
mutable_memory_validation.rs Use the informative error as the main const eval error message 2025-06-02 15:37:15 +00:00
mutable_memory_validation.stderr Use the informative error as the main const eval error message 2025-06-02 15:37:15 +00:00
nested-allocations-dont-inherit-codegen-attrs.rs Don't inherit codegen attrs from parent static 2024-03-31 22:34:00 -04:00
nested_struct.rs [Refactor] Rename Lint and LintGroup\'s is_loaded to is_externally_loaded 2024-04-29 15:57:09 +02:00
nested_thread_local.rs also stabilize const_refs_to_cell 2024-09-15 10:20:47 +02:00
nested_thread_local.stderr also stabilize const_refs_to_cell 2024-09-15 10:20:47 +02:00
read_before_init.rs const-eval: error when initializing a static writes to that static 2025-06-27 14:39:35 +02:00
read_before_init.stderr const-eval: error when initializing a static writes to that static 2025-06-27 14:39:35 +02:00
recursive_interior_mut.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
static-fn-inline-xc.rs tests: remove //@ pretty-expanded usages 2024-11-26 02:50:48 +08:00
static-fn-trait-xc.rs tests: remove //@ pretty-expanded usages 2024-11-26 02:50:48 +08:00
static-function-pointer-xc.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
static-function-pointer.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
static-impl.rs Use non-2015 edition paths in tests that do not test for their resolution 2025-06-05 09:19:31 +02:00
static-impl.stderr Update tests 2024-02-07 10:42:01 +08:00
static-method-in-trait-with-tps-intracrate.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
static-method-xcrate.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
static-methods-in-traits.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
static-methods-in-traits2.rs tests: remove //@ pretty-expanded usages 2024-11-26 02:50:48 +08:00
static-mut-shared-parens.rs Fix error message for static references or mutable references 2025-04-26 14:48:30 +09:00
static-mut-shared-parens.stderr Fix error message for static references or mutable references 2025-04-26 14:48:30 +09:00
static-mut-xc.rs Fix error message for static references or mutable references 2025-04-26 14:48:30 +09:00
static-mut-xc.stderr Fix error message for static references or mutable references 2025-04-26 14:48:30 +09:00
static-promotion.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
static-recursive.rs Fix error message for static references or mutable references 2025-04-26 14:48:30 +09:00
static-recursive.stderr Fix error message for static references or mutable references 2025-04-26 14:48:30 +09:00
uninhabited-static.rs Use the informative error as the main const eval error message 2025-06-02 15:37:15 +00:00
uninhabited-static.stderr const-eval error: always say in which item the error occurred 2025-06-07 13:42:30 +02:00
unsized_type2.rs Taint const qualifs if a static is referenced that didn't pass wfcheck 2024-04-16 10:43:41 +00:00
unsized_type2.stderr Tweak error code for sized checks of const/static 2025-03-03 23:09:42 +00:00
unsizing-wfcheck-issue-127299.rs Deduplicate dyn compatibility violations due to coercion 2025-05-26 10:57:54 +00:00
unsizing-wfcheck-issue-127299.stderr Deduplicate dyn compatibility violations due to coercion 2025-05-26 10:57:54 +00:00