Skip to content

Add a missing GenericTypeVisitable, and avoid having interner traits for FnSigKind and Abi#155562

Open
ChayimFriedman2 wants to merge 2 commits intorust-lang:mainfrom
ChayimFriedman2:no-traits
Open

Add a missing GenericTypeVisitable, and avoid having interner traits for FnSigKind and Abi#155562
ChayimFriedman2 wants to merge 2 commits intorust-lang:mainfrom
ChayimFriedman2:no-traits

Conversation

@ChayimFriedman2
Copy link
Copy Markdown
Contributor

r? types

@rustbot
Copy link
Copy Markdown
Collaborator

rustbot commented Apr 20, 2026

HIR ty lowering was modified

cc @fmease

This PR changes rustc_public

cc @oli-obk, @celinval, @ouz-a, @makai410

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Apr 20, 2026
@rust-log-analyzer

This comment has been minimized.

Instead, just use the concrete types `FnSigKind` and `rustc_abi::ExternAbi`. This simplifies the code in both rustc and rust-analyzer.
@rustbot
Copy link
Copy Markdown
Collaborator

rustbot commented Apr 20, 2026

The Miri subtree was changed

cc @rust-lang/miri

@rust-log-analyzer
Copy link
Copy Markdown
Collaborator

The job x86_64-gnu-gcc failed! Check out the build log: (web) (plain enhanced) (plain)

Click to see the possible cause of the failure (guessed by this bot)
---- [run-make] tests/run-make-cargo/rustc-crates-on-stable stdout ----

error: rmake recipe failed to complete
status: exit status: 1
command: cd "/checkout/obj/build/x86_64-unknown-linux-gnu/test/run-make-cargo/rustc-crates-on-stable/rmake_out" && env -u RUSTFLAGS -u __RUSTC_DEBUG_ASSERTIONS_ENABLED -u __STD_DEBUG_ASSERTIONS_ENABLED -u __STD_REMAP_DEBUGINFO_ENABLED AR="ar" BUILD_ROOT="/checkout/obj/build/x86_64-unknown-linux-gnu" CARGO="/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools-bin/cargo" CC="cc" CC_DEFAULT_FLAGS="-ffunction-sections -fdata-sections -fPIC -m64" CXX="c++" CXX_DEFAULT_FLAGS="-ffunction-sections -fdata-sections -fPIC -m64" HOST_RUSTC_DYLIB_PATH="/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib" LD_LIBRARY_PATH="/checkout/obj/build/x86_64-unknown-linux-gnu/bootstrap-tools/x86_64-unknown-linux-gnu/release/deps:/checkout/obj/build/x86_64-unknown-linux-gnu/stage0/lib/rustlib/x86_64-unknown-linux-gnu/lib" LD_LIB_PATH_ENVVAR="LD_LIBRARY_PATH" LLVM_BIN_DIR="/checkout/obj/build/x86_64-unknown-linux-gnu/ci-llvm/bin" LLVM_COMPONENTS="aarch64 aarch64asmparser aarch64codegen aarch64desc aarch64disassembler aarch64info aarch64utils abi aggressiveinstcombine all all-targets amdgpu amdgpuasmparser amdgpucodegen amdgpudesc amdgpudisassembler amdgpuinfo amdgputargetmca amdgpuutils analysis arm armasmparser armcodegen armdesc armdisassembler arminfo armutils asmparser asmprinter avr avrasmparser avrcodegen avrdesc avrdisassembler avrinfo binaryformat bitreader bitstreamreader bitwriter bpf bpfasmparser bpfcodegen bpfdesc bpfdisassembler bpfinfo cas cfguard cgdata codegen codegentypes core coroutines coverage csky cskyasmparser cskycodegen cskydesc cskydisassembler cskyinfo debuginfobtf debuginfocodeview debuginfodwarf debuginfodwarflowlevel debuginfogsym debuginfologicalview debuginfomsf debuginfopdb demangle dlltooldriver dtlto dwarfcfichecker dwarflinker dwarflinkerclassic dwarflinkerparallel dwp engine executionengine extensions filecheck frontendatomic frontenddirective frontenddriver frontendhlsl frontendoffloading frontendopenacc frontendopenmp fuzzercli fuzzmutate globalisel hexagon hexagonasmparser hexagoncodegen hexagondesc hexagondisassembler hexagoninfo hipstdpar instcombine instrumentation interfacestub interpreter ipo irprinter irreader jitlink libdriver lineeditor linker loongarch loongarchasmparser loongarchcodegen loongarchdesc loongarchdisassembler loongarchinfo lto m68k m68kasmparser m68kcodegen m68kdesc m68kdisassembler m68kinfo mc mca mcdisassembler mcjit mcparser mips mipsasmparser mipscodegen mipsdesc mipsdisassembler mipsinfo mirparser msp430 msp430asmparser msp430codegen msp430desc msp430disassembler msp430info native nativecodegen nvptx nvptxcodegen nvptxdesc nvptxinfo objcarcopts objcopy object objectyaml option orcdebugging orcjit orcshared orctargetprocess passes plugins powerpc powerpcasmparser powerpccodegen powerpcdesc powerpcdisassembler powerpcinfo profiledata remarks riscv riscvasmparser riscvcodegen riscvdesc riscvdisassembler riscvinfo riscvtargetmca runtimedyld sandboxir scalaropts selectiondag sparc sparcasmparser sparccodegen sparcdesc sparcdisassembler sparcinfo support supportlsp symbolize systemz systemzasmparser systemzcodegen systemzdesc systemzdisassembler systemzinfo tablegen target targetparser telemetry textapi textapibinaryreader transformutils vectorize webassembly webassemblyasmparser webassemblycodegen webassemblydesc webassemblydisassembler webassemblyinfo webassemblyutils windowsdriver windowsmanifest x86 x86asmparser x86codegen x86desc x86disassembler x86info x86targetmca xray xtensa xtensaasmparser xtensacodegen xtensadesc xtensadisassembler xtensainfo" LLVM_FILECHECK="/checkout/obj/build/x86_64-unknown-linux-gnu/ci-llvm/bin/FileCheck" PYTHON="/usr/bin/python3" RUSTC="/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" RUSTDOC="/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustdoc" SOURCE_ROOT="/checkout" TARGET="x86_64-unknown-linux-gnu" TARGET_EXE_DYLIB_PATH="/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/x86_64-unknown-linux-gnu/lib" __BOOTSTRAP_JOBS="4" __RMAKE_VERBOSE_SUBPROCESS_OUTPUT="1" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/run-make-cargo/rustc-crates-on-stable/rmake"
stdout: none
--- stderr -------------------------------
command failed at line 41
LD_LIBRARY_PATH="/checkout/obj/build/x86_64-unknown-linux-gnu/test/run-make-cargo/rustc-crates-on-stable/rmake_out:/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib:/checkout/obj/build/x86_64-unknown-linux-gnu/bootstrap-tools/x86_64-unknown-linux-gnu/release/deps:/checkout/obj/build/x86_64-unknown-linux-gnu/stage0/lib/rustlib/x86_64-unknown-linux-gnu/lib" RUSTC="/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" RUSTC_STAGE="0" RUSTFLAGS="-Zallow-features=" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools-bin/cargo" "build" "--manifest-path" "/checkout/Cargo.toml" "--no-default-features" "--target-dir" "target" "-p" "rustc_type_ir" "-p" "rustc_next_trait_solver" "-p" "rustc_pattern_analysis" "-p" "rustc_lexer" "-p" "rustc_abi" "-p" "rustc_parse_format" "-p" "rustc_hashes"
output status: `exit status: 101`
=== STDOUT ===



=== STDERR ===
    Blocking waiting for file lock on package cache
---
   |
25 | impl HomogeneousAggregate {
   | ------------------------- method in this implementation
...
38 |     fn merge(self, other: HomogeneousAggregate) -> Result<HomogeneousAggregate, Heterogeneous> {
   |        ^^^^^
   |
   = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default

   Compiling rustc_type_ir v0.0.0 (/checkout/compiler/rustc_type_ir)
---
    |
213 |     crate::FnSigKind<I>,
    |                     +++

error[E0277]: the trait bound `ExternAbi: generic_visit::GenericTypeVisitable<__V>` is not satisfied
##[error]  --> compiler/rustc_type_ir/src/error.rs:29:17
   |
23 | #[derive(TypeVisitable_Generic, GenericTypeVisitable)]
   |                                 --------------------
   |                                 |
   |                                 required by a bound introduced by this call
   |                                 in this derive macro expansion
...
29 |     AbiMismatch(#[type_visitable(ignore)] ExpectedFound<ExternAbi>),
   |                 ^ the trait `generic_visit::GenericTypeVisitable<__V>` is not implemented for `ExternAbi`
   |
   = help: the following other types implement trait `generic_visit::GenericTypeVisitable<V>`:
             CoroutineClosureSignature<I>
             ExpectedFound<T>
             ExternalConstraintsData<I>
             FnHeader<I>
             FnSigTys<I>
             GenSig<I>
             NestedNormalizationGoals<I>
             ProbeKind<I>
           and 44 others
note: required for `ExpectedFound<ExternAbi>` to implement `generic_visit::GenericTypeVisitable<__V>`
  --> compiler/rustc_type_ir/src/error.rs:10:12
   |
 9 | #[derive(TypeFoldable_Generic, TypeVisitable_Generic, GenericTypeVisitable)]
   |                                                       -------------------- type parameter would need to implement `generic_visit::GenericTypeVisitable<__V>`
10 | pub struct ExpectedFound<T> {
   |            ^^^^^^^^^^^^^^^^
   = help: consider manually implementing `generic_visit::GenericTypeVisitable<__V>` to avoid undesired bounds
   = note: this error originates in the derive macro `GenericTypeVisitable` (in Nightly builds, run with -Z macro-backtrace for more info)

Some errors have detailed explanations: E0107, E0277.
For more information about an error, try `rustc --explain E0107`.
warning: `rustc_type_ir` (lib) generated 1 warning
error: could not compile `rustc_type_ir` (lib) due to 2 previous errors; 1 warning emitted

For more information how to resolve CI failures of this job, visit this link.

@rust-bors
Copy link
Copy Markdown
Contributor

rust-bors bot commented Apr 20, 2026

☔ The latest upstream changes (presumably #155552) made this pull request unmergeable. Please resolve the merge conflicts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants