Oli Scherer
652ba279ec
Show the memory of uninit reads
2025-07-18 07:47:08 +00:00
Oli Scherer
12eedafc38
Report the range of uninit bytes in CTFE errors
2025-07-17 20:00:51 +00:00
Jakub Beránek
0093ca5c76
Rollup merge of #141610 - BoxyUwU:stabilize_generic_arg_infer, r=lcnr,traviscross
...
Stabilize `feature(generic_arg_infer)`
Fixes rust-lang/rust#85077
r? lcnr
cc ````@rust-lang/project-const-generics````
2025-06-18 18:06:49 +02:00
Matthias Krüger
2d9513b98c
Rollup merge of #142157 - Enselic:trivial-anon-const-use-cases, r=compiler-errors
...
rustc_resolve: Improve `resolve_const_param_in_non_trivial_anon_const` wording
In some contexts, const expressions are OK. Add a `here` to the error message to clarify this.
Closes rust-lang/rust#79429 which has 15 x 👍
2025-06-12 03:14:51 +02:00
Boxy
fe04ae7faf
stabilize gai
2025-06-11 15:30:15 +01:00
Ralf Jung
17946c22b1
const-eval error: always say in which item the error occurred
...
also adjust the wording a little so that we don't say "the error occurred here" for two different spans
2025-06-07 13:42:30 +02:00
Martin Nordholts
4882ea4b3c
rustc_resolve: Improve resolve_const_param_in_non_trivial_anon_const wording
...
In some contexts, const expressions are OK. Add a `here` to the error
message to clarify this.
2025-06-07 13:01:16 +02:00
Oli Scherer
020216c31c
Clarify why we are talking about a failed const eval at a random place
2025-06-02 15:37:15 +00:00
Oli Scherer
b331b8b96d
Use the informative error as the main const eval error message
2025-06-02 15:37:15 +00:00
Vadim Petrochenkov
20faf8532b
compiletest: Make diagnostic kind mandatory on line annotations
2025-04-30 10:44:24 +03:00
Oli Scherer
07fcead073
Always take the Ok path in lit_to_const and produce error constants instead
2025-01-09 08:48:00 +00:00
lcnr
f0ae48d106
add tests
2024-12-18 16:35:06 +01:00
lcnr
5f548890b8
add tests
2024-12-17 08:50:47 +01:00
Barrett Ray
c5598d6a9e
fix(hir_analysis/wfcheck): don't leak {type error}
...
avoid `{type error}` being leaked in user-facing messages,
particularly when using the `adt_const_params` feature
2024-09-29 23:40:43 -05:00
Boxy
d0c11bf6e3
Split part of adt_const_params into unsized_const_params
2024-07-17 11:01:29 +01:00
Oli Scherer
fd9a92542c
Automatically taint when reporting errors from ItemCtxt
2024-07-09 07:44:17 +00:00
Oli Scherer
86c8eae774
Automatically taint InferCtxt when errors are emitted
2024-06-26 16:01:45 +00:00
Michael Goulet
ce5f8c93fa
Bless test fallout (duplicate diagnostics)
2024-03-20 13:00:34 -04:00
Esteban Küber
6c31f6ce12
Provide structured suggestion for #![feature(foo)]
...
```
error: `S2<'_>` is forbidden as the type of a const generic parameter
--> $DIR/lifetime-in-const-param.rs:5:23
|
LL | struct S<'a, const N: S2>(&'a ());
| ^^
|
= note: the only supported types are integers, `bool` and `char`
help: add `#![feature(adt_const_params)]` to the crate attributes to enable more complex and user defined types
|
LL + #![feature(adt_const_params)]
|
```
Fix #55941 .
2024-03-18 16:08:58 +00:00
Urgau
80c81c53ac
Allow newly added non_local_definitions lint in tests
2024-02-17 13:59:45 +01:00
许杰友 Jieyou Xu (Joe)
ec2cc761bc
[AUTO-GENERATED] Migrate ui tests from // to //@ directives
2024-02-16 20:02:50 +00:00
Oli Scherer
0978f6e010
Avoid silencing relevant follow-up errors
2024-01-09 21:08:16 +00:00
Ralf Jung
1dbfe17f12
generic_const_exprs: suggest to add the feature, not use it
2023-11-30 20:59:51 +01:00
Nilstrieb
41e8d152dc
Show number in error message even for one error
...
Co-authored-by: Adrian <adrian.iosdev@gmail.com >
2023-11-24 19:15:52 +01:00
asquared31415
b53a1b3808
make adt_const_params feature suggestion more consistent with others and only suggest it when the type can probably work
2023-09-28 23:10:04 +00:00
Boxy
73b3ce26ec
improve diagnostics and bless tests
2023-05-05 21:42:54 +01:00
Lukas Markeffsky
31443c63b5
preserve delim spans during macro_rules! expansion if able
2023-01-20 20:16:37 +01:00
Albert Larsan
cf2dff2b1e
Move /src/test to /tests
2023-01-11 09:32:08 +00:00