take_while_with_pred in rustfmt_nightly::attr - Rust
Description: Returns the first group of attributes that fills the given predicate. We consider two doc comments are in different group if they are separated by normal comments.

Skip to main content

## take_while_with_pred

# Function take_while_with_pred

Source

    fn take_while_with_pred<'a, P>(
        context: &RewriteContext<'_>,
        attrs: &'a [Attribute],
        pred: P,
    ) -> &'a [Attribute]where
        P: Fn(&Attribute) -> bool,

Expand description

Returns the first group of attributes that fills the given predicate. We consider two doc comments are in different group if they are separated by normal comments.