rust/compiler/rustc_codegen_cranelift/src
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
..
abi Rename is_like_osx to is_like_darwin 2025-03-25 21:53:52 +01:00
debuginfo Rollup merge of #138949 - madsmtm:rename-to-darwin, r=WaffleLapkin 2025-04-04 08:02:05 +02:00
driver Auto merge of #139453 - compiler-errors:incr, r=jieyouxu 2025-04-11 13:59:33 +00:00
intrinsics update docs 2025-04-06 21:41:47 +02:00
optimize Reformat use declarations. 2024-07-29 08:26:52 +10:00
allocator.rs Remove implicit #[no_mangle] for #[rustc_std_internal_symbol] 2025-03-17 14:08:09 +00:00
analyze.rs rename AddressOf -> RawBorrow inside the compiler 2024-08-18 19:46:53 +02:00
base.rs Merge commit 'ba315abda7' into sync_cg_clif-2025-03-30 2025-03-30 15:43:48 +00:00
cast.rs Rustfmt 2025-02-08 22:12:13 +00:00
codegen_i128.rs Windows x86: Change i128 to return via the vector ABI 2025-01-27 12:12:59 +00:00
common.rs Merge commit 'ba315abda7' into sync_cg_clif-2025-03-30 2025-03-30 15:43:48 +00:00
compiler_builtins.rs Merge commit '8332329f83' into sync_cg_clif-2025-02-07 2025-02-07 20:58:27 +00:00
concurrency_limiter.rs Remove jobserver from Session 2024-12-13 10:21:22 +00:00
config.rs Merge commit 'ba315abda7' into sync_cg_clif-2025-03-30 2025-03-30 15:43:48 +00:00
constant.rs Rename is_like_osx to is_like_darwin 2025-03-25 21:53:52 +01:00
discriminant.rs make no-variant types a dedicated Variants variant 2024-12-18 11:01:54 +01:00
global_asm.rs Prepend temp files with a string per invocation of rustc 2025-04-07 20:48:40 +00:00
inline_asm.rs Merge commit 'ba315abda7' into sync_cg_clif-2025-03-30 2025-03-30 15:43:48 +00:00
lib.rs Prepend temp files with a string per invocation of rustc 2025-04-07 20:48:40 +00:00
linkage.rs Sync rustc_codegen_cranelift 'ddd4ce2553' 2021-04-30 14:49:58 +02:00
main_shim.rs Move has_self field to hir::AssocKind::Fn. 2025-04-14 16:13:04 +10:00
num.rs Merge commit 'ba315abda7' into sync_cg_clif-2025-03-30 2025-03-30 15:43:48 +00:00
pointer.rs Merge commit '1fa693ca44' into sync_cg_clif-2024-11-09 2024-11-09 13:48:06 +00:00
pretty_clif.rs Merge commit '1fa693ca44' into sync_cg_clif-2024-11-09 2024-11-09 13:48:06 +00:00
toolchain.rs Merge commit 'e9d1a0a7b0' into sync_cg_clif-2022-08-24 2022-08-24 18:40:58 +02:00
trap.rs Rustfmt 2025-02-08 22:12:13 +00:00
unsize.rs Use ExistentialTraitRef throughout codegen 2025-01-30 15:34:00 +00:00
unwind_module.rs Merge commit '49cd5dd454' into sync_cg_clif-2024-06-30 2024-06-30 11:28:14 +00:00
value_and_place.rs Merge commit 'ba315abda7' into sync_cg_clif-2025-03-30 2025-03-30 15:43:48 +00:00
vtable.rs Extend the renaming to coerce_unsafe_ptr 2025-02-10 13:01:55 +00:00