Skip to content

Commit 1a3dbe5

Browse files
committed
coverage: Make the fields of CoverageSpan non-public
The struct itself is already non-public, so making the fields non-public mostly just makes it much faster for rust-analyzer to find all references.
1 parent bf8716f commit 1a3dbe5

File tree

1 file changed

+6
-6
lines changed
  • compiler/rustc_mir_transform/src/coverage

1 file changed

+6
-6
lines changed

compiler/rustc_mir_transform/src/coverage/spans.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -65,14 +65,14 @@ impl CoverageSpans {
6565
/// `dominates()` the `BasicBlock`s in this `CoverageSpan`.
6666
#[derive(Debug, Clone)]
6767
struct CoverageSpan {
68-
pub span: Span,
69-
pub expn_span: Span,
70-
pub current_macro_or_none: OnceCell<Option<Symbol>>,
71-
pub bcb: BasicCoverageBlock,
68+
span: Span,
69+
expn_span: Span,
70+
current_macro_or_none: OnceCell<Option<Symbol>>,
71+
bcb: BasicCoverageBlock,
7272
/// List of all the original spans from MIR that have been merged into this
7373
/// span. Mainly used to precisely skip over gaps when truncating a span.
74-
pub merged_spans: Vec<Span>,
75-
pub is_closure: bool,
74+
merged_spans: Vec<Span>,
75+
is_closure: bool,
7676
}
7777

7878
impl CoverageSpan {

0 commit comments

Comments
 (0)