rust/src
Trevor Gross 3b45f8f310
Rollup merge of #130764 - compiler-errors:inherent, r=estebank
Separate collection of crate-local inherent impls from error tracking

#119895 changed the return type of the `crate_inherent_impls` query from `CrateInherentImpls` to `Result<CrateInherentImpls, ErrorGuaranteed>` to avoid needing to use the non-parallel-friendly `track_errors()` to track if an error was reporting from within the query... This was mostly fine until #121113, which stopped halting compilation when we hit an `Err(ErrorGuaranteed)` in the `crate_inherent_impls` query.

Thus we proceed onwards to typeck, and since a return type of `Result<CrateInherentImpls, ErrorGuaranteed>` means that the query can *either* return one of "the list inherent impls" or "error has been reported", later on when we want to assemble method or associated item candidates for inherent impls, we were just treating any `Err(ErrorGuaranteed)` return value as if Rust had no inherent impls defined anywhere at all! This leads to basically every inherent method call failing with an error, lol, which was reported in #127798.

This PR changes the `crate_inherent_impls` query to return `(CrateInherentImpls, Result<(), ErrorGuaranteed>)`, i.e. returning the inherent impls collected *and* whether an error was reported in the query itself. It firewalls the latter part of that query into a new `crate_inherent_impls_validity_check` just for the `ensure()` call.

This fixes #127798.
2024-09-24 19:47:50 -04:00
..
bootstrap Auto merge of #130620 - onur-ozkan:update-make-prepare, r=Kobzol 2024-09-23 22:19:24 +00:00
ci Reformat using the new identifier sorting from rustfmt 2024-09-22 19:11:29 -04:00
doc Rollup merge of #130759 - rustbot:docs-update, r=ehuss 2024-09-23 23:49:13 -04:00
etc Reformat using the new identifier sorting from rustfmt 2024-09-22 19:11:29 -04:00
gcc@fd3498bff0 Update GCC version 2024-09-06 16:01:46 +02:00
librustdoc Fix tools 2024-09-24 10:12:05 -04:00
llvm-project@5699773936 Update to LLVM 19.1.0 2024-09-20 14:41:36 -07:00
rustdoc-json-types rustdoc: normalise type/field names in rustdoc-json-types/jsondoclint 2024-09-01 23:58:08 +03:00
tools Rollup merge of #130764 - compiler-errors:inherent, r=estebank 2024-09-24 19:47:50 -04:00
README.md
stage0 Bump stage0 2024-09-22 19:04:19 -04:00
version

This directory contains some source code for the Rust project, including:

  • The bootstrapping build system
  • Various submodules for tools, like cargo, tidy, etc.

For more information on how various parts of the compiler work, see the rustc dev guide.