Skip to content

view-types: propagate view types to rustc_middle#159291

Draft
scrabsha wants to merge 1 commit into
rust-lang:mainfrom
scrabsha:view-types/in-mir
Draft

view-types: propagate view types to rustc_middle#159291
scrabsha wants to merge 1 commit into
rust-lang:mainfrom
scrabsha:view-types/in-mir

Conversation

@scrabsha

@scrabsha scrabsha commented Jul 14, 2026

Copy link
Copy Markdown
Contributor

⚠️ this PR is big and boring and need self-review. review from other people is welcome, but it is probably not worth your time (at least in its current state) ⚠️

TODO:

  • PR description
  • tracking issue
  • maybe some tests?

@rustbot rustbot added A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. PG-exploit-mitigations Project group: Exploit mitigations S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. WG-trait-system-refactor The Rustc Trait System Refactor Initiative (-Znext-solver) labels Jul 14, 2026
@rust-log-analyzer

This comment has been minimized.

@scrabsha scrabsha force-pushed the view-types/in-mir branch from e9822b0 to 4600dd1 Compare July 14, 2026 14:42
@rust-log-analyzer

This comment has been minimized.

@scrabsha scrabsha force-pushed the view-types/in-mir branch from 4600dd1 to e2963ed Compare July 14, 2026 15:28
@rust-log-analyzer

This comment has been minimized.

@scrabsha scrabsha force-pushed the view-types/in-mir branch from e2963ed to 15cc52f Compare July 15, 2026 09:44
@rustbot rustbot added the T-clippy Relevant to the Clippy team. label Jul 15, 2026
@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/build/run_make_support/a300432cf10d6d08/out:/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/build/run_make_support/a300432cf10d6d08/out:/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="-D warnings -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 ===
   Compiling unicode-ident v1.0.24
---
   Compiling tracing v0.1.41
   Compiling rustc_abi v0.0.0 (/checkout/compiler/rustc_abi)
   Compiling rustc_pattern_analysis v0.0.0 (/checkout/compiler/rustc_pattern_analysis)
   Compiling rustc_type_ir v0.0.0 (/checkout/compiler/rustc_type_ir)
error[E0277]: the trait bound `FieldSetVid: generic_visit::GenericTypeVisitable<__V>` is not satisfied
##[error]   --> compiler/rustc_type_ir/src/ty_kind.rs:314:42
    |
144 | #[derive(GenericTypeVisitable)]
    |          --------------------
    |          |
    |          required by a bound introduced by this call
    |          in this derive macro expansion
...
314 |     ViewInfer(I::AdtDef, I::GenericArgs, FieldSetVid),
    |                                          ^^^^^^^^^^^ unsatisfied trait bound
    |
help: the trait `generic_visit::GenericTypeVisitable<__V>` is not implemented for `FieldSetVid`
   --> compiler/rustc_type_ir/src/ty_kind.rs:776:1
    |
776 | / rustc_index::newtype_index! {
777 | |     /// A **field set** **v**ariable **ID**.
778 | |     #[encodable]
779 | |     #[orderable]
780 | |     #[debug_format = "?{}"]
781 | |     #[gate_rustc_only]
782 | |     pub struct FieldSetVid {}
    | |__________________________^
    = help: the following other types implement trait `generic_visit::GenericTypeVisitable<V>`:
              AccessedOpaques<I>
              CoroutineClosureSignature<I>
              ExpectedFound<T>
              ExternalConstraintsData<I>
              ExternalRegionConstraints<I>
              FnHeader<I>
              FnSigTys<I>
              GenSig<I>
            and 46 others
    = note: this error originates in the derive macro `GenericTypeVisitable` which comes from the expansion of the macro `rustc_index::newtype_index` (in Nightly builds, run with -Z macro-backtrace for more info)

For more information about this error, try `rustc --explain E0277`.
error: could not compile `rustc_type_ir` (lib) due to 1 previous error

Important

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

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

Labels

A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. PG-exploit-mitigations Project group: Exploit mitigations S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. T-clippy Relevant to the Clippy team. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. WG-trait-system-refactor The Rustc Trait System Refactor Initiative (-Znext-solver)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants