Skip to content

Make MatchOptions::new const #102

@kangalio

Description

@kangalio

Little quality of life change that would allow you to create static glob configurations for use throughout the program, like this

pub const CASE_INSENSITIVE_GLOB: glob::MatchOptions = glob::MatchOptions {
    case_sensitive: false,
    ..glob::MatchOptions::new()
};

glob::glob_with("...", CASE_INSENSITIVE_GLOB)

Of course you can easily work around this by manually specifying all the fields. It would be convenient to be able to fill in default values, though :)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions