Skip to content

Commit 0d57b22

Browse files
compiler: Indicate parse::Capturing #[default]
1 parent e0192f4 commit 0d57b22

File tree

1 file changed

+3
-2
lines changed
  • compiler/rustc_parse/src/parser

1 file changed

+3
-2
lines changed

compiler/rustc_parse/src/parser/mod.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -211,9 +211,10 @@ pub type ReplaceRange = (Range<u32>, Vec<(FlatToken, Spacing)>);
211211
/// Controls how we capture tokens. Capturing can be expensive,
212212
/// so we try to avoid performing capturing in cases where
213213
/// we will never need an `AttrTokenStream`.
214-
#[derive(Copy, Clone)]
214+
#[derive(Copy, Clone, Default)]
215215
pub enum Capturing {
216-
/// We aren't performing any capturing - this is the default mode.
216+
/// We aren't performing any capturing
217+
#[default]
217218
No,
218219
/// We are capturing tokens
219220
Yes,

0 commit comments

Comments
 (0)