Skip to content

filter_entry().filter_entry() is broken #192

@obsgolem

Description

@obsgolem

FilterEntry::filter_entry is parameterized on the global P instead of a new, local P. This means that you can't call filter_entry twice with two different functions.

EDIT:
Minimal repro:

use walkdir::WalkDir;

fn main() {
    let temp = WalkDir::new(".")
        .into_iter()
        .filter_entry(|x| true)
        .filter_entry(|x| true);
}

Playground link

Expected: compiles
Actual: doesn't

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions