rust/tests/ui/typeck
bors 9629b90b3f Auto merge of #127722 - BoxyUwU:new_adt_const_params_limitations, r=compiler-errors
Forbid borrows and unsized types from being used as the type of a const generic under `adt_const_params`

Fixes #112219
Fixes #112124
Fixes #112125

### Motivation

Currently the `adt_const_params` feature allows writing `Foo<const N: [u8]>` this is entirely useless as it is not possible to write an expression which evaluates to a type that is not `Sized`. In order to actually use unsized types in const generics they are typically written as `const N: &[u8]` which *is* possible to provide a value of.

Unfortunately allowing the types of const parameters to contain references is non trivial (#120961) as it introduces a number of difficult questions about how equality of references in the type system should behave. References in the types of const generics is largely only useful for using unsized types in const generics.

This PR introduces a new feature gate `unsized_const_parameters` and moves support for `const N: [u8]` and `const N: &...` from `adt_const_params` into it. The goal here hopefully is to experiment with allowing `const N: [u8]` to work without references and then eventually completely forbid references in const generics.

Splitting this out into a new feature gate means that stabilization of `adt_const_params` does not have to resolve #120961 which is the only remaining "big" blocker for the feature. Remaining issues after this are a few ICEs and naming bikeshed for `ConstParamTy`.

### Implementation

The implementation is slightly subtle here as we would like to ensure that a stabilization of `adt_const_params` is forwards compatible with any outcome of `unsized_const_parameters`. This is inherently tricky as we do not support unstable trait implementations and we determine whether a type is valid as the type of a const parameter via a trait bound.

There are a few constraints here:
- We would like to *allow for the possibility* of adding a `Sized` supertrait to `ConstParamTy` in the event that we wind up opting to not support unsized types and instead requiring people to write the 'sized version', e.g. `const N: [u8; M]` instead of `const N: [u8]`.
- Crates should be able to enable `unsized_const_parameters` and write trait implementations of `ConstParamTy` for `!Sized` types without downstream crates that only enable `adt_const_params` being able to observe this (required for std to be able to `impl<T> ConstParamTy for [T]`

Ultimately the way this is accomplished is via having two traits (sad), `ConstParamTy` and `UnsizedConstParamTy`. Depending on whether `unsized_const_parameters` is enabled or not we change which trait is used to check whether a type is allowed to be a const parameter.

Long term (when stabilizing `UnsizedConstParamTy`) it should be possible to completely merge these traits (and derive macros), only having a single `trait ConstParamTy` and `macro ConstParamTy`.

Under `adt_const_params` it is now illegal to directly refer to `ConstParamTy` it is only used as an internal impl detail by `derive(ConstParamTy)` and checking const parameters are well formed. This is necessary in order to ensure forwards compatibility with all possible future directions for `feature(unsized_const_parameters)`.

Generally the intuition here should be that `ConstParamTy` is the stable trait that everything uses, and `UnsizedConstParamTy` is that plus unstable implementations (well, I suppose `ConstParamTy` isn't stable yet :P).
2024-07-21 05:36:21 +00:00
..
auxiliary [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-87181 Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-114918 Add ConstArgKind::Path and make ConstArg its own HIR node 2024-07-16 19:27:28 -07:00
apit-with-error-type-in-sig.rs Don't call a type uncallable if its signature has errors in it 2023-07-22 15:27:21 +00:00
apit-with-error-type-in-sig.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
assign-non-lval-derefmut.fixed [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
assign-non-lval-derefmut.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
assign-non-lval-derefmut.stderr Change E0369 diagnostic give note information for foreign items. 2024-06-25 10:00:30 +08:00
assign-non-lval-mut-ref.fixed [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
assign-non-lval-mut-ref.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
assign-non-lval-mut-ref.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
assign-non-lval-needs-deref.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
assign-non-lval-needs-deref.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
autoderef-with-param-env-error.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
autoderef-with-param-env-error.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
bad-index-due-to-nested.rs Test downstream errors from bad index expr 2023-04-18 19:25:57 +00:00
bad-index-due-to-nested.stderr Provide more context on derived obligation error primary label 2024-01-30 21:28:18 +00:00
bad-index-modulo-higher-ranked-regions.rs Don't ICE when ambiguity is found when selecting Index implementation in typeck 2023-11-20 23:37:04 +00:00
bad-index-modulo-higher-ranked-regions.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
bad-recursive-type-sig-infer.rs Don't infer fn return type to return itself 2023-04-22 19:30:47 +00:00
bad-recursive-type-sig-infer.stderr Don't infer fn return type to return itself 2023-04-22 19:30:47 +00:00
bad-type-in-vec-contains.rs Fix another ICE in point_at_expr_source_of_inferred_type 2023-03-02 18:27:06 +00:00
bad-type-in-vec-contains.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
bad-type-in-vec-push.rs Hack to suppress bad labels in type mismatch inference deduction code 2023-01-23 17:02:50 +00:00
bad-type-in-vec-push.stderr Make note_source_of_type_mismatch_constraint simpler 2023-04-12 23:05:55 +00:00
call-block.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
call-block.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
check-args-on-fn-err-2.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
check-args-on-fn-err-2.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
check-args-on-fn-err.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
check-args-on-fn-err.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
conversion-methods.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
conversion-methods.stderr Modify primary span label for E0308 2023-01-30 20:12:19 +00:00
cyclic_type_ice.rs Continue reporting remaining errors instead of silently dropping them 2024-02-13 14:56:20 +00:00
cyclic_type_ice.stderr Use ordinal number in argument error 2024-07-14 13:50:09 +09:00
deref-multi.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
deref-multi.stderr Modify primary span label for E0308 2023-01-30 20:12:19 +00:00
derive-sugg-arg-arity.rs Don't use can_eq in derive suggestion for missing method 2023-05-12 20:34:51 +00:00
derive-sugg-arg-arity.stderr Use single label for method not found due to unmet bound 2024-01-26 20:47:19 +00:00
do-not-suggest-adding-missing-zero-to-floating-point-number.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
do-not-suggest-adding-missing-zero-to-floating-point-number.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
do-not-suggest-placeholder-to-const-static-without-type.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
do-not-suggest-placeholder-to-const-static-without-type.stderr Make parse error suggestions verbose and fix spans 2024-07-12 03:02:57 +00:00
dont-record-adjustments-when-pointing-at-arg.rs Don't record adjustments twice in note_source_of_type_mismatch_constraint 2023-06-12 00:35:30 +00:00
dont-record-adjustments-when-pointing-at-arg.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
escaping_bound_vars.rs Rename HIR TypeBinding to AssocItemConstraint and related cleanup 2024-05-30 22:52:33 +02:00
escaping_bound_vars.stderr Rename HIR TypeBinding to AssocItemConstraint and related cleanup 2024-05-30 22:52:33 +02:00
explain_clone_autoref.rs Added recursive checking back up to see if a Clone suggestion would be helpful. 2023-07-25 10:09:26 +01:00
explain_clone_autoref.stderr Added recursive checking back up to see if a Clone suggestion would be helpful. 2023-07-25 10:09:26 +01:00
ice-self-mismatch-const-generics.rs Pass the correct DefId when suggesting writing the aliased Self type out 2024-03-14 19:39:15 +00:00
ice-self-mismatch-const-generics.stderr Pass the correct DefId when suggesting writing the aliased Self type out 2024-03-14 19:39:15 +00:00
ice-unexpected-region-123863.rs Fix ICE on invalid const param types 2024-04-27 09:36:38 +05:30
ice-unexpected-region-123863.stderr Split part of adt_const_params into unsized_const_params 2024-07-17 11:01:29 +01:00
ice-with-expr-not-struct-127332.rs Move a span_bug under a condition that cx is tainted 2024-07-07 15:44:55 +05:30
ice-with-expr-not-struct-127332.stderr Move a span_bug under a condition that cx is tainted 2024-07-07 15:44:55 +05:30
invalid-stashed-level-issue-121812.rs Handle stashing of delayed bugs. 2024-03-01 10:18:54 +11:00
invalid-stashed-level-issue-121812.stderr Handle stashing of delayed bugs. 2024-03-01 10:18:54 +11:00
issue-1871.rs Move tests 2023-05-24 19:35:59 -03:00
issue-1871.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-2063-resource.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-2063.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-7813.rs Move tests 2023-02-16 11:42:35 -03:00
issue-7813.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-10401.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-10401.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-10969.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-10969.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-13853-2.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-13853-2.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-13853-5.rs Merge check_mod_impl_wf and check_mod_type_wf 2024-03-07 06:27:09 +00:00
issue-13853-5.stderr Merge check_mod_impl_wf and check_mod_type_wf 2024-03-07 06:27:09 +00:00
issue-13853.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-13853.stderr Note that type param is chosen by caller when suggesting return impl Trait 2024-03-16 23:20:42 +00:00
issue-16338.rs Move some tests 2024-02-09 15:43:08 -03:00
issue-16338.stderr Move some tests 2024-02-09 15:43:08 -03:00
issue-18937-1.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-18937.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-18937.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-22375.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-29124.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-29124.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-29181.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-29181.stderr Move issue 29181, 2804, 17431, 66768 2023-08-24 20:44:08 +03:00
issue-31173.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-31173.stderr tests: remove some trailing ws 2024-04-27 10:54:31 +03:00
issue-33575.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-33575.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-36708.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-36708.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-43189.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-43189.stderr Tweak wording of "implemented trait isn't imported" suggestion 2024-02-22 18:05:27 +00:00
issue-46112.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-46112.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-50687-ice-on-borrow.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-50687-ice-on-borrow.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-52082-type-param-shadows-existing-type.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-52082-type-param-shadows-existing-type.stderr recover primary span label 2023-11-16 17:00:23 +00:00
issue-53712.rs Tweak slice and as_deref suggestion span 2024-07-04 05:50:21 +00:00
issue-53712.stderr Tweak raw-pointer field access and array indexing suggestions 2024-07-04 06:06:33 +00:00
issue-55810-must-typeck-match-pats-before-guards.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-57404.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-57404.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-57673-ice-on-deref-of-boxed-trait.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-57673-ice-on-deref-of-boxed-trait.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-61711-once-caused-rustc-inf-loop.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-65611.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-65611.stderr recover primary span label 2023-11-16 17:00:23 +00:00
issue-67971.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-67971.stderr recover primary span label 2023-11-16 17:00:23 +00:00
issue-68590-reborrow-through-derefmut.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-69378-ice-on-invalid-type-node-after-recovery.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-69378-ice-on-invalid-type-node-after-recovery.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-72225-call-fnmut-through-derefmut.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-73592-borrow_mut-through-deref.fixed [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-73592-borrow_mut-through-deref.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-73592-borrow_mut-through-deref.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-74086.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-74086.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-74933.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-75883.rs diagnostics: remove inconsistent English article "this" from E0107 2023-02-23 10:27:06 -07:00
issue-75883.stderr diagnostics: remove inconsistent English article "this" from E0107 2023-02-23 10:27:06 -07:00
issue-75889.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-75889.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-79040.rs Avoid silencing relevant follow-up errors 2024-01-09 21:08:16 +00:00
issue-79040.stderr Make parse error suggestions verbose and fix spans 2024-07-12 03:02:57 +00:00
issue-80207-unsized-return.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-80779.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-80779.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-81293.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-81293.stderr Spell out other trait diagnostic 2024-06-12 12:34:47 +00:00
issue-81885.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-81885.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-81943.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-81943.stderr Inline get_node_fn_decl into get_fn_decl, simplify/explain logic in report_return_mismatched_types 2024-05-20 20:16:29 -04:00
issue-82772.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-82772.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-83621-placeholder-static-in-extern.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-83621-placeholder-static-in-extern.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-83693.rs Rename HIR TypeBinding to AssocItemConstraint and related cleanup 2024-05-30 22:52:33 +02:00
issue-83693.stderr Rename HIR TypeBinding to AssocItemConstraint and related cleanup 2024-05-30 22:52:33 +02:00
issue-84160.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-84160.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-84768.rs Rename HIR TypeBinding to AssocItemConstraint and related cleanup 2024-05-30 22:52:33 +02:00
issue-84768.stderr Rename HIR TypeBinding to AssocItemConstraint and related cleanup 2024-05-30 22:52:33 +02:00
issue-84831.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-84831.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-86721-return-expr-ice.rev1.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-86721-return-expr-ice.rev2.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-86721-return-expr-ice.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-87771-ice-assign-assign-to-bool.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-87771-ice-assign-assign-to-bool.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-87872-missing-inaccessible-field-literal.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-87872-missing-inaccessible-field-literal.stderr Tweak message on ADT with private fields building 2023-11-29 18:11:57 +00:00
issue-87872-missing-inaccessible-field-pattern.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-87872-missing-inaccessible-field-pattern.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-88609.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-88643.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-88643.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-88803-call-expr-method.fixed [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-88803-call-expr-method.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-88803-call-expr-method.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-88844.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-88844.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-89044-wrapped-expr-method.fixed [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-89044-wrapped-expr-method.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-89044-wrapped-expr-method.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-89275.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-89275.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-89806.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-89806.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-89856.fixed [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-89856.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-89856.stderr More robust as_ref/as_deref suggestions 2023-06-08 16:30:05 +00:00
issue-89935.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-90027-async-fn-return-suggestion.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-90027-async-fn-return-suggestion.stderr Point to where missing return type should go 2023-10-04 21:09:54 +00:00
issue-90101.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-90101.stderr Spell out other trait diagnostic 2024-06-12 12:34:47 +00:00
issue-90164.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-90164.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-90319.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-90319.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-90483-inaccessible-field-adjustment.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-90483-inaccessible-field-adjustment.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-90804-incorrect-reference-suggestion.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-90804-incorrect-reference-suggestion.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-91210-ptr-method.fixed [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-91210-ptr-method.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-91210-ptr-method.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-91267.rs Rename HIR TypeBinding to AssocItemConstraint and related cleanup 2024-05-30 22:52:33 +02:00
issue-91267.stderr Rename HIR TypeBinding to AssocItemConstraint and related cleanup 2024-05-30 22:52:33 +02:00
issue-91328.fixed [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-91328.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-91328.stderr Tweak slice and as_deref suggestion span 2024-07-04 05:50:21 +00:00
issue-91334.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-91334.stderr remove duplicated diagnostic for unclosed delimiter 2023-02-28 07:57:17 +00:00
issue-91450-inner-ty-error.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-91450-inner-ty-error.stderr Modify primary span label for E0308 2023-01-30 20:12:19 +00:00
issue-91633.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-92481.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-92481.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-93486.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-93486.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-96530.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-96530.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-96738.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-96738.stderr recover primary span label 2023-11-16 17:00:23 +00:00
issue-98260.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-98260.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-98982.rs Remove note about iteration count in coerce 2024-04-30 12:46:59 +05:30
issue-98982.stderr Remove note about iteration count in coerce 2024-04-30 12:46:59 +05:30
issue-100164.fixed [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-100164.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-100164.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-100246.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-100246.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-100285.rs Remove note about iteration count in coerce 2024-04-30 12:46:59 +05:30
issue-100285.stderr Remove note about iteration count in coerce 2024-04-30 12:46:59 +05:30
issue-103899.rs Mark some next-solver-behavior tests explicitly with revisions 2024-03-10 23:23:46 -04:00
issue-104510-ice.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-104510-ice.stderr don't skip coercions for types with errors 2024-02-10 23:13:47 +01:00
issue-104513-ice.rs Split note, fix const/static impl trait error 2024-01-07 18:00:03 +00:00
issue-104513-ice.stderr Split note, fix const/static impl trait error 2024-01-07 18:00:03 +00:00
issue-104582.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-104582.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-105946.rs Remove uses of box_syntax in rustc and tools 2023-03-12 13:19:46 +00:00
issue-105946.stderr Bless tests 2024-01-13 12:46:58 -05:00
issue-106929.rs Don't typecheck suggested method call 2023-05-30 17:57:37 +08:00
issue-106929.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-107087.rs Use proper InferCtxt when probing for associated types in astconv 2023-01-23 16:53:23 +00:00
issue-107087.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-107775.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-107775.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-110017-format-into-help-deletes-macro.fixed [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-110017-format-into-help-deletes-macro.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-110017-format-into-help-deletes-macro.stderr Fix suggestions span for when expr is from macro expansions 2023-06-28 17:54:20 +08:00
issue-110052.rs Avoid silencing relevant follow-up errors 2024-01-09 21:08:16 +00:00
issue-110052.stderr Update test outputs 2023-12-22 11:01:07 -08:00
issue-112007-leaked-writeln-macro-internals.rs test: avoid running rustfix on leaked writeln macro internals test 2024-04-10 19:37:48 +00:00
issue-112007-leaked-writeln-macro-internals.stderr test: avoid running rustfix on leaked writeln macro internals test 2024-04-10 19:37:48 +00:00
issue-112252-ptr-arithmetics-help.fixed [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-112252-ptr-arithmetics-help.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-112252-ptr-arithmetics-help.stderr Improve spans for indexing expressions 2023-08-04 13:17:39 +02:00
issue-112385-while-assign-lhs-place-expr-ice.rs Fix ICE for while loop with assignment condition with LHS place expr 2023-06-08 02:38:12 +08:00
issue-112385-while-assign-lhs-place-expr-ice.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-114423-ice-regression-in-suggestion.rs Rename issue #114423 test files to include context 2023-08-05 09:04:47 +08:00
issue-114423-ice-regression-in-suggestion.stderr Rename issue #114423 test files to include context 2023-08-05 09:04:47 +08:00
issue-114529-illegal-break-with-value.rs Typeck break expr even if break is illegal 2023-11-20 15:14:08 +05:30
issue-114529-illegal-break-with-value.stderr Typeck break expr even if break is illegal 2023-11-20 15:14:08 +05:30
issue-116473-ice-wrong-span-variant-args.rs macro_rules: Preserve all metavariable spans in a global side table 2024-02-18 11:19:24 +03:00
issue-116473-ice-wrong-span-variant-args.stderr macro_rules: Preserve all metavariable spans in a global side table 2024-02-18 11:19:24 +03:00
issue-116864.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
issue-120856.rs Loosen an assertion to account for stashed errors. 2024-02-10 09:14:59 +11:00
issue-120856.stderr Loosen an assertion to account for stashed errors. 2024-02-10 09:14:59 +11:00
method-chain-gats.rs Properly deal with GATs when looking for method chains to point at 2024-03-03 00:42:03 +01:00
method-chain-gats.stderr Properly deal with GATs when looking for method chains to point at 2024-03-03 00:42:03 +01:00
mismatched-map-under-self.rs Adjust inner span of implicit self ref argument 2023-06-28 17:51:01 +00:00
mismatched-map-under-self.stderr Use verbose suggestion for changing arg type 2024-07-05 20:58:33 +00:00
missing-private-fields-in-struct-literal.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
missing-private-fields-in-struct-literal.stderr Tweak message on ADT with private fields building 2023-11-29 18:11:57 +00:00
no-type-for-node-ice.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
no-type-for-node-ice.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
nonexistent-field-not-ambiguous.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
nonexistent-field-not-ambiguous.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
output-type-mismatch.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
output-type-mismatch.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
path-to-method-sugg-unresolved-expr.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
path-to-method-sugg-unresolved-expr.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
pin-unsound-issue-85099-derefmut.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
point-at-type-param-in-path-expr.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
point-at-type-param-in-path-expr.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
point-at-type-parameter-definition.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
point-at-type-parameter-definition.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
prim-with-args.fixed [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
prim-with-args.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
prim-with-args.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
project-cache-issue-37154.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
ptr-null-mutability-suggestions.fixed [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
ptr-null-mutability-suggestions.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
ptr-null-mutability-suggestions.stderr Use verbose suggestion for ptr::null_mut() 2024-07-05 20:38:21 +00:00
question-mark-operator-suggestion-span.rs test: check that ? suggestion has local span 2024-04-10 19:37:48 +00:00
question-mark-operator-suggestion-span.stderr test: check that ? suggestion has local span 2024-04-10 19:37:48 +00:00
quiet-type-err-let-binding.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
quiet-type-err-let-binding.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
remove-extra-argument.fixed [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
remove-extra-argument.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
remove-extra-argument.stderr Use ordinal number in argument error 2024-07-14 13:50:09 +09:00
remove-semi-but-confused-char.rs Don't use bytepos offsets when computing semicolon span for removal 2024-04-09 14:06:08 -04:00
remove-semi-but-confused-char.stderr Don't use bytepos offsets when computing semicolon span for removal 2024-04-09 14:06:08 -04:00
repeat-expr-checks-wf.rs check array type of repeat exprs is wf 2023-05-04 11:22:40 +01:00
repeat-expr-checks-wf.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
return-dyn-type-mismatch-2.rs only suppress coercion error if type is definitely unsized 2023-06-02 16:38:08 +00:00
return-dyn-type-mismatch-2.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
return-dyn-type-mismatch.rs only suppress coercion error if type is definitely unsized 2023-06-02 16:38:08 +00:00
return-dyn-type-mismatch.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
return_type_containing_closure.rs Use suggest_impl_trait in return type suggestion 2024-04-10 18:58:15 -04:00
return_type_containing_closure.stderr Use suggest_impl_trait in return type suggestion 2024-04-10 18:58:15 -04:00
slow-lhs-suggestion.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
slow-lhs-suggestion.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
span-bug-issue-121410.rs Revert some span_bugs to span_delayed_bug. 2024-02-23 08:35:18 +11:00
span-bug-issue-121410.stderr Revert some span_bugs to span_delayed_bug. 2024-02-23 08:35:18 +11:00
struct-enum-wrong-args.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
struct-enum-wrong-args.stderr Use ordinal number in argument error 2024-07-14 13:50:09 +09:00
struct-index-err-ice-issue-126744.rs report pat no field error no recoverd struct variant 2024-07-11 00:18:47 +08:00
struct-index-err-ice-issue-126744.stderr report pat no field error no recoverd struct variant 2024-07-11 00:18:47 +08:00
suggest-adding-missing-zero-to-floating-point-number.fixed [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
suggest-adding-missing-zero-to-floating-point-number.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
suggest-adding-missing-zero-to-floating-point-number.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
suggest-box-on-divergent-if-else-arms.fixed [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
suggest-box-on-divergent-if-else-arms.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
suggest-box-on-divergent-if-else-arms.stderr Suggest boxing both arms of if expr if that solves divergent arms involving impl Trait 2024-01-23 04:42:26 +00:00
suggest-similar-impls-for-root-obligation.rs Stop passing traitref/traitpredicate by ref 2024-06-12 20:57:24 -04:00
suggest-similar-impls-for-root-obligation.stderr Bless and add ICE regression test 2024-06-12 20:57:23 -04:00
suppressed-error.rs Move some UI tests into subdirectories 2023-04-02 19:42:30 -04:00
suppressed-error.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
tag-that-dare-not-speak-its-name.rs Move some UI tests into subdirectories 2023-04-02 19:42:30 -04:00
tag-that-dare-not-speak-its-name.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
terr-in-field.rs Move some UI tests into subdirectories 2023-04-02 19:42:30 -04:00
terr-in-field.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
terr-sorts.rs Move some UI tests into subdirectories 2023-04-02 19:42:30 -04:00
terr-sorts.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
type-placeholder-fn-in-const.rs properly check associated consts for infer placeholders 2023-06-11 00:27:03 +00:00
type-placeholder-fn-in-const.stderr Merge collect_mod_item_types query into check_well_formed 2024-03-07 14:26:31 +00:00
typeck-builtin-bound-type-parameters.rs Avoid silencing relevant follow-up errors 2024-01-09 21:08:16 +00:00
typeck-builtin-bound-type-parameters.stderr Merge collect_mod_item_types query into check_well_formed 2024-03-07 14:26:31 +00:00
typeck-cast-pointer-to-float.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
typeck-cast-pointer-to-float.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
typeck-closure-to-unsafe-fn-ptr.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
typeck-default-trait-impl-assoc-type.fixed [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
typeck-default-trait-impl-assoc-type.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
typeck-default-trait-impl-assoc-type.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
typeck-default-trait-impl-cross-crate-coherence.rs Remove suspicious auto trait lint 2024-02-19 17:41:48 -03:00
typeck-default-trait-impl-cross-crate-coherence.stderr Remove suspicious auto trait lint 2024-02-19 17:41:48 -03:00
typeck-default-trait-impl-negation-send.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
typeck-default-trait-impl-negation-send.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
typeck-default-trait-impl-negation-sync.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
typeck-default-trait-impl-negation-sync.stderr Provide more context on derived obligation error primary label 2024-01-30 21:28:18 +00:00
typeck-default-trait-impl-send-param.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
typeck-default-trait-impl-send-param.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
typeck-fn-to-unsafe-fn-ptr.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
typeck-unsafe-always-share.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
typeck-unsafe-always-share.stderr Provide more context on derived obligation error primary label 2024-01-30 21:28:18 +00:00
typeck_type_placeholder_1.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
typeck_type_placeholder_item.rs Fix a error suggestion for E0121 when using placeholder _ as return types on function signature. 2024-06-29 14:23:33 +08:00
typeck_type_placeholder_item.stderr Fix a error suggestion for E0121 when using placeholder _ as return types on function signature. 2024-06-29 14:23:33 +08:00
typeck_type_placeholder_item_help.rs Avoid silencing relevant follow-up errors 2024-01-09 21:08:16 +00:00
typeck_type_placeholder_item_help.stderr Use the same collection order as check_mod_type_wf 2024-03-07 13:37:06 +00:00
typeck_type_placeholder_lifetime_1.rs diagnostics: remove inconsistent English article "this" from E0107 2023-02-23 10:27:06 -07:00
typeck_type_placeholder_lifetime_1.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
typeck_type_placeholder_lifetime_2.rs diagnostics: remove inconsistent English article "this" from E0107 2023-02-23 10:27:06 -07:00
typeck_type_placeholder_lifetime_2.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
typeck_type_placeholder_mismatch.rs Modify primary span label for E0308 2023-01-30 20:12:19 +00:00
typeck_type_placeholder_mismatch.stderr Modify primary span label for E0308 2023-01-30 20:12:19 +00:00
ufcs-type-params.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
unify-return-ty.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
while-loop-block-cond.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
while-loop-block-cond.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
while-type-error.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
while-type-error.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
wrong-ret-type.rs [AUTO-GENERATED] Migrate ui tests from // to //@ directives 2024-02-16 20:02:50 +00:00
wrong-ret-type.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00