Method in prelude · Option auto-imported

Option::filter

pub fn filter(T -> bool pred) -> Option<T>
Source: compiler/src/prelude/core.hy

This option if its value passes pred, otherwise None.

Called on a Option value as value.filter(…).

Parameters#

NameType
predT -> bool

Returns#

Option<T>

See also#

↑ ↓ navigate ↵ open