Auto merge of #113303 - compiler-errors:yeet-chalk, r=lcnr

Remove chalk support from the compiler

Removes chalk (`-Ztrait-solver=chalk`) from the compiler and prunes any dead code resulting from this, mainly:
* Remove the chalk compatibility layer in `compiler/rustc_traits/src/chalk`
* Remove the chalk flag `-Ztrait-solver=chalk` and its `TraitEngine` implementation
* Remove `TypeWellFormedFromEnv` (and its many `bug!()` match arms)
* Remove the chalk migration mode from compiletest
* Remove the `chalkify` UI tests (do we want to keep any of these, but migrate them to `-Ztrait-solver=next`??)

Fulfills rust-lang/types-team#93.

r? `@jackh726`
This commit is contained in:
bors 2023-07-04 09:09:09 +00:00
commit cd68ead9ec
89 changed files with 35 additions and 3864 deletions

View file

@ -304,7 +304,7 @@ pub enum Subcommand {
./x.py test library/std --test-args hash_map
./x.py test library/std --stage 0 --no-doc
./x.py test tests/ui --bless
./x.py test tests/ui --compare-mode chalk
./x.py test tests/ui --compare-mode next-solver
Note that `test tests/* --stage N` does NOT depend on `build compiler/rustc --stage N`;
just like `build library/std --stage N` it tests the compiler produced by the previous
stage.

View file

@ -342,8 +342,7 @@ pub(crate) fn clean_predicate<'tcx>(
// FIXME(generic_const_exprs): should this do something?
ty::ClauseKind::ConstEvaluatable(..)
| ty::ClauseKind::WellFormed(..)
| ty::ClauseKind::ConstArgHasType(..)
| ty::ClauseKind::TypeWellFormedFromEnv(..) => None,
| ty::ClauseKind::ConstArgHasType(..) => None,
}
}

View file

@ -107,7 +107,6 @@ string_enum! {
#[derive(Clone, Debug, PartialEq)]
pub enum CompareMode {
Polonius => "polonius",
Chalk => "chalk",
NextSolver => "next-solver",
NextSolverCoherence => "next-solver-coherence",
SplitDwarf => "split-dwarf",

View file

@ -2435,9 +2435,6 @@ impl<'test> TestCx<'test> {
Some(CompareMode::Polonius) => {
rustc.args(&["-Zpolonius"]);
}
Some(CompareMode::Chalk) => {
rustc.args(&["-Ztrait-solver=chalk"]);
}
Some(CompareMode::NextSolver) => {
rustc.args(&["-Ztrait-solver=next"]);
}

View file

@ -122,10 +122,6 @@ const PERMITTED_RUSTC_DEPENDENCIES: &[&str] = &[
"byteorder", // via ruzstd in object in thorin-dwp
"cc",
"cfg-if",
"chalk-derive",
"chalk-engine",
"chalk-ir",
"chalk-solve",
"compiler_builtins",
"convert_case", // dependency of derive_more
"cpufeatures",
@ -149,7 +145,6 @@ const PERMITTED_RUSTC_DEPENDENCIES: &[&str] = &[
"fallible-iterator", // dependency of `thorin`
"fastrand",
"field-offset",
"fixedbitset",
"flate2",
"fluent-bundle",
"fluent-langneg",
@ -199,7 +194,6 @@ const PERMITTED_RUSTC_DEPENDENCIES: &[&str] = &[
"parking_lot_core",
"pathdiff",
"perf-event-open-sys",
"petgraph",
"pin-project-lite",
"polonius-engine",
"ppv-lite86",

View file

@ -11,7 +11,7 @@ use std::path::{Path, PathBuf};
const ENTRY_LIMIT: usize = 900;
// FIXME: The following limits should be reduced eventually.
const ISSUES_ENTRY_LIMIT: usize = 1896;
const ROOT_ENTRY_LIMIT: usize = 871;
const ROOT_ENTRY_LIMIT: usize = 870;
const EXPECTED_TEST_FILE_EXTENSIONS: &[&str] = &[
"rs", // test source files