Macro cfg_find_map

Source
macro_rules! cfg_find_map {
    ($object:expr, $closure:expr) => { ... };
}
Expand description

Applies a function and returns an entry where lambda(e) is not None.

ยงNotes

  • This returns at most one entry that satisfies the given condition, not necessarily the first one.
  • closure must be a lambda function returning Option, e.g., |e| Some(e).