Skip to content

Commit b012615

Browse files
committed
extend Polonius options helpers
1 parent a946fab commit b012615

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

compiler/rustc_session/src/config.rs

+6-1
Original file line numberDiff line numberDiff line change
@@ -3427,7 +3427,7 @@ pub enum Polonius {
34273427
/// Legacy version, using datalog and the `polonius-engine` crate. Historical value for `-Zpolonius`.
34283428
Legacy,
34293429

3430-
/// In-tree experimentation
3430+
/// In-tree prototype, extending the NLL infrastructure.
34313431
Next,
34323432
}
34333433

@@ -3442,4 +3442,9 @@ impl Polonius {
34423442
pub fn is_legacy_enabled(&self) -> bool {
34433443
matches!(self, Polonius::Legacy)
34443444
}
3445+
3446+
/// Returns whether the "next" version of polonius is enabled
3447+
pub fn is_next_enabled(&self) -> bool {
3448+
matches!(self, Polonius::Next)
3449+
}
34453450
}

0 commit comments

Comments
 (0)