diff options
| author | bors <bors@rust-lang.org> | 2020-11-15 02:21:18 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2020-11-15 02:21:18 +0000 |
| commit | 75042566d1c90d912f22e4db43b6d3af98447986 (patch) | |
| tree | 59ffa44ee35633cf8ff80b132e2cf0919c3dd787 /compiler/rustc_mir/src/transform/coverage/debug.rs | |
| parent | 361c4ea22486557ec50c4fc6a93d60e7476ecbea (diff) | |
| parent | 96515ccc7a41cc8968ee742cb4d65205582e0fe9 (diff) | |
| download | rust-75042566d1c90d912f22e4db43b6d3af98447986.tar.gz rust-75042566d1c90d912f22e4db43b6d3af98447986.zip | |
Auto merge of #79065 - Dylan-DPC:rollup-gag1drk, r=Dylan-DPC
Rollup of 15 pull requests Successful merges: - #78352 (Do not call `unwrap` with `signatures` option enabled) - #78590 (refactor: removing alloc::collections::vec_deque ignore-tidy-filelength) - #78848 (Bump minimal supported LLVM version to 9) - #78856 (Explicitly checking for or-pattern before test) - #78948 (test: add `()=()=()=...` to weird-exprs.rs) - #78962 (Add a test for r# identifiers) - #78963 (Added some unit tests as requested) - #78966 (Never inline C variadics, cold functions, functions with incompatible attributes ...) - #78968 (Include llvm-as in llvm-tools-preview component) - #78969 (Normalize function type during validation) - #78980 (Fix rustc_ast_pretty print_qpath resulting in invalid macro input) - #78986 (Avoid installing external LLVM dylibs) - #78988 (Fix an intrinsic invocation on threaded wasm) - #78993 (rustc_target: Fix dash vs underscore mismatches in option names) - #79013 (Clean up outdated `use_once_payload` pretty printer comment) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Diffstat (limited to 'compiler/rustc_mir/src/transform/coverage/debug.rs')
| -rw-r--r-- | compiler/rustc_mir/src/transform/coverage/debug.rs | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/compiler/rustc_mir/src/transform/coverage/debug.rs b/compiler/rustc_mir/src/transform/coverage/debug.rs index ffa795134e2..7f1dc3844b2 100644 --- a/compiler/rustc_mir/src/transform/coverage/debug.rs +++ b/compiler/rustc_mir/src/transform/coverage/debug.rs @@ -127,7 +127,7 @@ pub const NESTED_INDENT: &str = " "; const RUSTC_COVERAGE_DEBUG_OPTIONS: &str = "RUSTC_COVERAGE_DEBUG_OPTIONS"; -pub(crate) fn debug_options<'a>() -> &'a DebugOptions { +pub(super) fn debug_options<'a>() -> &'a DebugOptions { static DEBUG_OPTIONS: SyncOnceCell<DebugOptions> = SyncOnceCell::new(); &DEBUG_OPTIONS.get_or_init(|| DebugOptions::from_env()) @@ -136,7 +136,7 @@ pub(crate) fn debug_options<'a>() -> &'a DebugOptions { /// Parses and maintains coverage-specific debug options captured from the environment variable /// "RUSTC_COVERAGE_DEBUG_OPTIONS", if set. #[derive(Debug, Clone)] -pub(crate) struct DebugOptions { +pub(super) struct DebugOptions { pub allow_unused_expressions: bool, counter_format: ExpressionFormat, } @@ -250,7 +250,7 @@ impl Default for ExpressionFormat { /// /// `DebugCounters` supports a recursive rendering of `Expression` counters, so they can be /// presented as nested expressions such as `(bcb3 - (bcb0 + bcb1))`. -pub(crate) struct DebugCounters { +pub(super) struct DebugCounters { some_counters: Option<FxHashMap<ExpressionOperandId, DebugCounter>>, } @@ -386,7 +386,7 @@ impl DebugCounter { /// If enabled, this data structure captures additional debugging information used when generating /// a Graphviz (.dot file) representation of the `CoverageGraph`, for debugging purposes. -pub(crate) struct GraphvizData { +pub(super) struct GraphvizData { some_bcb_to_coverage_spans_with_counters: Option<FxHashMap<BasicCoverageBlock, Vec<(CoverageSpan, CoverageKind)>>>, some_bcb_to_dependency_counters: Option<FxHashMap<BasicCoverageBlock, Vec<CoverageKind>>>, @@ -496,7 +496,7 @@ impl GraphvizData { /// directly or indirectly, to compute the coverage counts for all `CoverageSpan`s, and any that are /// _not_ used are retained in the `unused_expressions` Vec, to be included in debug output (logs /// and/or a `CoverageGraph` graphviz output). -pub(crate) struct UsedExpressions { +pub(super) struct UsedExpressions { some_used_expression_operands: Option<FxHashMap<ExpressionOperandId, Vec<InjectedExpressionId>>>, some_unused_expressions: @@ -626,7 +626,7 @@ impl UsedExpressions { } /// Generates the MIR pass `CoverageSpan`-specific spanview dump file. -pub(crate) fn dump_coverage_spanview( +pub(super) fn dump_coverage_spanview( tcx: TyCtxt<'tcx>, mir_body: &mir::Body<'tcx>, basic_coverage_blocks: &CoverageGraph, @@ -666,7 +666,7 @@ fn span_viewables( } /// Generates the MIR pass coverage-specific graphviz dump file. -pub(crate) fn dump_coverage_graphviz( +pub(super) fn dump_coverage_graphviz( tcx: TyCtxt<'tcx>, mir_body: &mir::Body<'tcx>, pass_name: &str, @@ -815,7 +815,7 @@ fn bcb_to_string_sections( /// Returns a simple string representation of a `TerminatorKind` variant, indenpendent of any /// values it might hold. -pub(crate) fn term_type(kind: &TerminatorKind<'tcx>) -> &'static str { +pub(super) fn term_type(kind: &TerminatorKind<'tcx>) -> &'static str { match kind { TerminatorKind::Goto { .. } => "Goto", TerminatorKind::SwitchInt { .. } => "SwitchInt", |
