fn apply_on_current_line_or_unwrap<'a, F: FnOnce(String) -> &'a str>(
fun: F,
default: &'a str,
) -> StringExpand description
Apply a closure to the current line or fall back to default.
Used by the smart expr mapping helpers.
In case of errors, they are notified to Nvim and a default value is returned.