Feature gate: #![feature(const_bool_to_option)]
This is a tracking issue for const bool::then{,_some} functions.
See also #80967
Public API
// core::bool
impl bool {
pub const fn then_some<T>(self, t: T) -> Option<T>
where
T: ~const Drop;
pub const fn then<T, F>(self, f: F) -> Option<T>
where
F: ~const FnOnce() -> T,
F: ~const Drop;
}
Steps / History
Unresolved Questions
Feature gate:
#![feature(const_bool_to_option)]This is a tracking issue for
constbool::then{,_some}functions.See also #80967
Public API
Steps / History
bool::then{,_some}#91918Unresolved Questions