rust/tests/ui/traits/next-solver
Nicholas Nethercote ce2aa97cd6 Move has_self field to hir::AssocKind::Fn.
`hir::AssocItem` currently has a boolean `fn_has_self_parameter` field,
which is misplaced, because it's only relevant for associated fns, not
for associated consts or types. This commit moves it (and renames it) to
the `AssocKind::Fn` variant, where it belongs.

This requires introducing a new C-style enum, `AssocTag`, which is like
`AssocKind` but without the fields. This is because `AssocKind` values
are passed to various functions like `find_by_ident_and_kind` to
indicate what kind of associated item should be searched for, and having
to specify `has_self` isn't relevant there.

New methods:
- Predicates `AssocItem::is_fn` and `AssocItem::is_method`.
- `AssocItem::as_tag` which converts `AssocItem::kind` to `AssocTag`.

Removed `find_by_name_and_kinds`, which is unused.

`AssocItem::descr` can now distinguish between methods and associated
functions, which slightly improves some error messages.
2025-04-14 16:13:04 +10:00
..
alias-relate Implement #[define_opaque] attribute for functions. 2025-03-11 12:05:02 +00:00
assembly
canonical Manually walk into WF obligations in BestObligation proof tree visitor 2025-01-31 18:21:58 +00:00
coherence change definitely non-productive cycles to error 2025-03-05 10:06:43 +01:00
cycles keep inductive cycles as ambig in coherence 2025-03-05 10:06:43 +01:00
diagnostics UI tests: add missing diagnostic kinds where possible 2025-04-08 23:06:31 +03:00
generalize resolve FIXME 2024-12-18 16:35:06 +01:00
method eagerly prove WF when resolving fully qualified paths 2025-02-14 00:04:22 +01:00
normalization-shadowing handle global trait bounds defining assoc type 2025-01-20 18:51:45 +01:00
normalize Move has_self field to hir::AssocKind::Fn. 2025-04-14 16:13:04 +10:00
opaques replace //@ compile-flags: --edition with //@ edition 2025-04-10 09:56:37 +02:00
overflow Deeply normalize obligations in BestObligation 2025-04-10 18:58:04 +00:00
typeck Auto merge of #133559 - compiler-errors:structurally-resolve-adjust-for-branch, r=lcnr 2024-12-06 04:55:35 +00:00
alias-bound-preference.rs
alias-bound-unsound.rs Bless tests due to extra error reporting due to normalizing types that are not WF 2024-11-27 03:34:58 +00:00
alias-bound-unsound.stderr Bless tests due to extra error reporting due to normalizing types that are not WF 2024-11-27 03:34:58 +00:00
alias-eq-in-canonical-response.rs
alias-sub.rs
ambiguous-impl-in-resolve.rs
array-default.rs
async.fail.stderr Deeply normalize obligations in BestObligation 2025-04-10 18:58:04 +00:00
async.rs Deeply normalize obligations in BestObligation 2025-04-10 18:58:04 +00:00
auto-with-drop_tracking_mir.fail.stderr Remove detail from label/note that is already available in other note 2024-10-29 16:26:57 +00:00
auto-with-drop_tracking_mir.rs
borrowck-error.rs
borrowck-error.stderr
builtin-fn-must-return-sized.rs UI tests: add missing diagnostic kinds where possible 2025-04-08 23:06:31 +03:00
builtin-fn-must-return-sized.stderr Remove detail from label/note that is already available in other note 2024-10-29 16:26:57 +00:00
cast-checks-handling-projections.rs
closure-inference-guidance.rs
closure-signature-inference-2.rs
closure-signature-inference-hr-ambig-alias-naming-self.rs "normalize" signature before checking mentions self 2025-01-28 14:11:29 +00:00
closure-signature-inference.rs
closure-substs-ambiguity.rs
coerce-ambig-alias-to-rigid-alias.rs
const-param-placeholder.fail.stderr
const-param-placeholder.rs
constrain-alias-goals-in-unsize.rs
coroutine.fail.stderr Be better at reporting alias errors 2024-10-15 20:42:17 -04:00
coroutine.rs fix tests 2024-11-02 16:58:50 +00:00
deduce-ty-from-object.rs
dedup-regions.rs
destruct.rs Gate const drop behind const_destruct feature, and fix const_precise_live_drops post-drop-elaboration check 2024-11-22 16:54:40 +00:00
dont-canonicalize-re-error.rs
dont-canonicalize-re-error.stderr
dont-coerce-infer-to-dyn.rs
dont-elaborate-for-projections.rs
dont-ice-on-assoc-projection.rs
dont-ice-on-assoc-projection.stderr
dont-ice-on-bad-transmute-in-typeck.rs Don't ice on bad transmute in typeck in new solver 2025-01-06 17:56:16 +00:00
dont-ice-on-bad-transmute-in-typeck.stderr Don't ice on bad transmute in typeck in new solver 2025-01-06 17:56:16 +00:00
dont-loop-fulfill-on-region-constraints.rs
dont-normalize-proj-with-error.rs
dont-normalize-proj-with-error.stderr
dyn-any-dont-prefer-impl.rs
dyn-incompatibility.rs Register a dummy candidate for failed structural normalization during candiate assembly 2024-10-15 20:42:17 -04:00
dyn-incompatibility.stderr Use trait name instead of full constraint in suggestion message 2024-12-07 21:29:58 +00:00
elaborate-item-bounds.rs
escaping-bound-vars-in-writeback-normalization.rs
float-canonical.rs
fn-trait-closure.rs
fn-trait.rs
fn-trait.stderr Be better at reporting alias errors 2024-10-15 20:42:17 -04:00
gat-wf.rs UI tests: add missing diagnostic kinds where possible 2025-04-08 23:06:31 +03:00
gat-wf.stderr Deeply normalize associated type bounds before proving them 2025-02-17 17:21:24 +00:00
global-cache-and-parallel-frontend.rs compiler: Inform the solver of concurrency 2024-09-09 13:07:48 -07:00
global-cache-and-parallel-frontend.stderr Do not suggest using -Zmacro-backtrace for builtin macros 2025-03-14 19:50:03 +00:00
higher-ranked-dyn-bounds.rs
int-var-alias-eq.rs
int-var-is-send.rs
issue-118950-root-region.rs Assert that obligations are empty before deeply normalizing 2024-12-02 22:51:18 +00:00
issue-118950-root-region.stderr Mention type parameter in more cases and don't suggest ~const bound already there 2024-12-07 21:37:13 +00:00
iter-filter-projection.rs
known-type-outlives-has-constraints.rs Make sure to scrape region constraints from deeply normalizing type outlives assumptions in borrowck 2025-01-14 19:13:18 +00:00
lazy-nested-obligations-1.rs
lazy-nested-obligations-2.rs
lazy-nested-obligations-3.rs
more-object-bound.rs Deeply normalize obligations in BestObligation 2025-04-10 18:58:04 +00:00
more-object-bound.stderr Deeply normalize obligations in BestObligation 2025-04-10 18:58:04 +00:00
nested-alias-bound.rs
nested-obligations-with-bound-vars-gat.rs
non-wf-in-coerce-pointers.rs Don't ICE in coerce when autoderef fails to structurally normalize non-WF type in new solver 2025-01-22 19:13:52 +00:00
non-wf-in-coerce-pointers.stderr Don't ICE in coerce when autoderef fails to structurally normalize non-WF type in new solver 2025-01-22 19:13:52 +00:00
non-wf-ret.rs Check xform_ret_ty for WF in the new solver to improve method winnowing 2024-11-27 20:46:08 +00:00
normalize-in-implied_outlives_bounds.rs Deeply normalize when computing implied outlives bounds 2024-12-02 22:51:17 +00:00
object-soundness-requires-generalization.rs tests: ensure disabled tests have a reason 2025-04-12 15:24:25 +08:00
opportunistic-region-resolve.rs
param-discr-kind.rs
pointee.rs
pointer-like.rs
pointer-like.stderr
prefer-candidate-no-constraints.rs
prefer-param-env-on-ambiguity.rs
projection-discr-kind.rs
projection-discr-kind.stderr
slice-match-byte-lit.rs
specialization-transmute.rs Pass spans around new solver 2025-02-05 18:32:06 +00:00
specialization-transmute.stderr Pass spans around new solver 2025-02-05 18:32:06 +00:00
specialization-unconstrained.rs
specialization-unconstrained.stderr
stall-num-var-auto-trait.fallback.stderr
stall-num-var-auto-trait.rs
structural-resolve-field.rs
structurally-normalize-in-borrowck-field-projection.rs Structurally resolve before applying projection in borrowck 2024-11-27 20:39:49 +00:00
trait-upcast-lhs-needs-normalization.rs remove feature(trait_upcasting) from tests and bless them 2025-02-06 23:44:23 +01:00
try-example.rs
unevaluated-const-impl-trait-ref.fails.stderr
unevaluated-const-impl-trait-ref.rs
unsafe-auto-trait-impl.rs
unsize-although-ambiguous.rs
unsize-good.rs Delete tuple unsizing 2025-02-27 10:26:33 +00:00
unsound-region-obligation.rs Pass spans around new solver 2025-02-05 18:32:06 +00:00
unsound-region-obligation.stderr Pass spans around new solver 2025-02-05 18:32:06 +00:00
upcast-right-substs.rs remove feature(trait_upcasting) from tests and bless them 2025-02-06 23:44:23 +01:00
upcast-wrong-substs.rs
upcast-wrong-substs.stderr
well-formed-in-relate.rs Allow WellFormed goals to be returned from relating in new solver 2025-03-24 16:57:06 +00:00
well-formed-in-relate.stderr Allow WellFormed goals to be returned from relating in new solver 2025-03-24 16:57:06 +00:00
winnow-specializing-impls.rs