Implement IntoIterator
for GlobSetBuilder
#3025
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Originally reported here: BurntSushi/globset#8
This PR fixes the linked issue. See below:
The
Debug
implementation ofGlobSetBuilder
is quite noisy. For better introspectability in consuming packages, it would be perfect if one of two things could be implemented, so theDebug
implementation can be adjusted (favorite) or is more readable:IntoIterator<Item = &Glob>
implementation for&GlobSetBuilder
, so we can use theDisplay
implementation ofGlob
where applicable. This would be a non-invasive addition, as the consumer can decide what style they want.Debug
implementation forGlobSetBuilder
that does 1., i.e., printsGlob
viaDisplay
.I'm happy to send a PR for either of which, if this is a good match.
Example
Current Result
Ideal Result:
Oh and thanks for this library, it is awesome!