1
Fork 0

Rename debugging_opts to unstable_opts

This is no longer used only for debugging options (e.g. `-Zoutput-width`, `-Zallow-features`).
Rename it to be more clear.
This commit is contained in:
Joshua Nelson 2022-07-06 07:44:47 -05:00
parent c80dde43f9
commit 3c9765cff1
125 changed files with 396 additions and 394 deletions

View file

@ -79,8 +79,8 @@ impl<K: DepKind> DepNode<K> {
#[cfg(debug_assertions)]
{
if !tcx.fingerprint_style(kind).reconstructible()
&& (tcx.sess().opts.debugging_opts.incremental_info
|| tcx.sess().opts.debugging_opts.query_dep_graph)
&& (tcx.sess().opts.unstable_opts.incremental_info
|| tcx.sess().opts.unstable_opts.query_dep_graph)
{
tcx.dep_graph().register_dep_node_debug_str(dep_node, || arg.to_debug_str(tcx));
}

View file

@ -347,7 +347,7 @@ impl<K: DepKind> DepGraph<K> {
let current_fingerprint =
hash_result.map(|f| dcx.with_stable_hashing_context(|mut hcx| f(&mut hcx, &result)));
let print_status = cfg!(debug_assertions) && dcx.sess().opts.debugging_opts.dep_tasks;
let print_status = cfg!(debug_assertions) && dcx.sess().opts.unstable_opts.dep_tasks;
// Intern the new `DepNode`.
let (dep_node_index, prev_and_color) = data.current.intern_node(

View file

@ -24,7 +24,7 @@ pub struct StableHashingContext<'a> {
cstore: &'a dyn CrateStore,
source_span: &'a IndexVec<LocalDefId, Span>,
// The value of `-Z incremental-ignore-spans`.
// This field should only be used by `debug_opts_incremental_ignore_span`
// This field should only be used by `unstable_opts_incremental_ignore_span`
incremental_ignore_spans: bool,
pub(super) body_resolver: BodyResolver<'a>,
// Very often, we are hashing something that does not need the
@ -57,14 +57,14 @@ impl<'a> StableHashingContext<'a> {
always_ignore_spans: bool,
) -> Self {
let hash_spans_initial =
!always_ignore_spans && !sess.opts.debugging_opts.incremental_ignore_spans;
!always_ignore_spans && !sess.opts.unstable_opts.incremental_ignore_spans;
StableHashingContext {
body_resolver: BodyResolver::Forbidden,
definitions,
cstore,
source_span,
incremental_ignore_spans: sess.opts.debugging_opts.incremental_ignore_spans,
incremental_ignore_spans: sess.opts.unstable_opts.incremental_ignore_spans,
caching_source_map: None,
raw_source_map: sess.source_map(),
hashing_controls: HashingControls { hash_spans: hash_spans_initial },
@ -186,7 +186,7 @@ impl<'a> rustc_span::HashStableContext for StableHashingContext<'a> {
}
#[inline]
fn debug_opts_incremental_ignore_spans(&self) -> bool {
fn unstable_opts_incremental_ignore_spans(&self) -> bool {
self.incremental_ignore_spans
}

View file

@ -467,7 +467,7 @@ where
if let Some(result) = result {
if std::intrinsics::unlikely(
tcx.dep_context().sess().opts.debugging_opts.query_dep_graph,
tcx.dep_context().sess().opts.unstable_opts.query_dep_graph,
) {
dep_graph.mark_debug_loaded_from_disk(*dep_node)
}
@ -486,7 +486,7 @@ where
// give us some coverage of potential bugs though.
let try_verify = prev_fingerprint.as_value().1 % 32 == 0;
if std::intrinsics::unlikely(
try_verify || tcx.dep_context().sess().opts.debugging_opts.incremental_verify_ich,
try_verify || tcx.dep_context().sess().opts.unstable_opts.incremental_verify_ich,
) {
incremental_verify_ich(*tcx.dep_context(), &result, dep_node, query);
}