where method
In case theres a value, keep it in case the predicate
is true
,
otherwise return None.
Implementation
Maybe<T> where(bool Function(T) predicate /*!*/) => _self.visit<Maybe<T>>(
just: (v) => predicate(v) ? _self : None<T>(),
none: () => _self,
);