diff options
| author | Boxy <supbscripter@gmail.com> | 2023-07-04 09:13:10 +0100 |
|---|---|---|
| committer | Boxy <supbscripter@gmail.com> | 2023-07-04 09:13:10 +0100 |
| commit | 2ad00f471a14581b7fafb0cdaf87173c8adb6c26 (patch) | |
| tree | fbe119a67148d3d82ef53dd8b111c9302fb95cb4 /compiler | |
| parent | 040aa58d0a5e35b73c487e395e3d59263de188ff (diff) | |
| download | rust-2ad00f471a14581b7fafb0cdaf87173c8adb6c26.tar.gz rust-2ad00f471a14581b7fafb0cdaf87173c8adb6c26.zip | |
reviews
Diffstat (limited to 'compiler')
| -rw-r--r-- | compiler/rustc_session/src/config.rs | 2 | ||||
| -rw-r--r-- | compiler/rustc_session/src/options.rs | 10 | ||||
| -rw-r--r-- | compiler/rustc_trait_selection/src/solve/eval_ctxt.rs | 4 |
3 files changed, 8 insertions, 8 deletions
diff --git a/compiler/rustc_session/src/config.rs b/compiler/rustc_session/src/config.rs index 996e106cf85..ece056afafc 100644 --- a/compiler/rustc_session/src/config.rs +++ b/compiler/rustc_session/src/config.rs @@ -748,7 +748,7 @@ pub enum TraitSolver { #[derive(Default, Debug, Copy, Clone, Hash, PartialEq, Eq)] pub enum SolverProofTreeCondition { #[default] - Never, + OnRequest, Always, OnError, } diff --git a/compiler/rustc_session/src/options.rs b/compiler/rustc_session/src/options.rs index e04e1d75287..5256237336c 100644 --- a/compiler/rustc_session/src/options.rs +++ b/compiler/rustc_session/src/options.rs @@ -418,7 +418,8 @@ mod desc { "a `,` separated combination of `bti`, `b-key`, `pac-ret`, or `leaf`"; pub const parse_proc_macro_execution_strategy: &str = "one of supported execution strategies (`same-thread`, or `cross-thread`)"; - pub const parse_solver_proof_tree_condition: &str = "one of: `always`, `never`, `on_error`"; + pub const parse_solver_proof_tree_condition: &str = + "one of: `always`, `on-request`, `on-error`"; } mod parse { @@ -1246,7 +1247,7 @@ mod parse { ) -> bool { match v { None | Some("always") => *slot = SolverProofTreeCondition::Always, - Some("never") => *slot = SolverProofTreeCondition::Never, + Some("on-request") => *slot = SolverProofTreeCondition::OnRequest, Some("on-error") => *slot = SolverProofTreeCondition::OnError, _ => return false, }; @@ -1477,8 +1478,9 @@ options! { "output statistics about monomorphization collection"), dump_mono_stats_format: DumpMonoStatsFormat = (DumpMonoStatsFormat::Markdown, parse_dump_mono_stats, [UNTRACKED], "the format to use for -Z dump-mono-stats (`markdown` (default) or `json`)"), - dump_solver_proof_tree: SolverProofTreeCondition = (SolverProofTreeCondition::Never, parse_solver_proof_tree_condition, [UNTRACKED], - "dump a proof tree for every goal evaluated by the new trait solver. The default is `always`"), + dump_solver_proof_tree: SolverProofTreeCondition = (SolverProofTreeCondition::OnRequest, parse_solver_proof_tree_condition, [UNTRACKED], + "dump a proof tree for every goal evaluated by the new trait solver. If the flag is specified without any options after it + then it defaults to `always`. If the flag is not specified at all it defaults to `on-request`."), dump_solver_proof_tree_uses_cache: Option<bool> = (None, parse_opt_bool, [UNTRACKED], "determines whether proof tree generation uses the global cache"), dwarf_version: Option<u32> = (None, parse_opt_number, [TRACKED], diff --git a/compiler/rustc_trait_selection/src/solve/eval_ctxt.rs b/compiler/rustc_trait_selection/src/solve/eval_ctxt.rs index 9fe860fe114..1d7c5a13068 100644 --- a/compiler/rustc_trait_selection/src/solve/eval_ctxt.rs +++ b/compiler/rustc_trait_selection/src/solve/eval_ctxt.rs @@ -196,9 +196,7 @@ impl<'a, 'tcx> EvalCtxt<'a, 'tcx> { } (_, None, GenerateProofTree::Yes(_)) => generate_proof_tree, - // `Never` is kind of weird- it doesn't actually force us to not generate proof trees - // its just the default setting for rustflags forced proof tree generation. - (SolverProofTreeCondition::Never, _, _) => generate_proof_tree, + (SolverProofTreeCondition::OnRequest, _, _) => generate_proof_tree, (SolverProofTreeCondition::OnError, _, _) => generate_proof_tree, }; |
