Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Simplify walker to use PatternMatcher instead of custom matching #108

Merged
merged 1 commit into from
Sep 2, 2021

Conversation

aaronlehmann
Copy link
Collaborator

This changes the pattern matching implementation in walker to use PatternMatcher, making it consistent with the "copy" code.

This makes it support ** patterns as well, which formerly didn't work.

The added benchmark shows the new implementation is slightly faster than the old one.

Opened on top of #107 - the first commit is from that PR, so only look at the second one.

Replaces #79

cc @coryb

@aaronlehmann
Copy link
Collaborator Author

Rebased now that #107 is merged.

Copy link
Collaborator

@coryb coryb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, thanks for carrying this work!

walker_test.go Outdated Show resolved Hide resolved
This changes the pattern matching implementation in walker to use
PatternMatcher, making it consistent with the "copy" code.

This makes it support ** patterns as well, which formerly didn't work.

The added benchmark shows the new implementation is slightly faster than
the old one.
@aaronlehmann
Copy link
Collaborator Author

@tonistiigi: Do you see any compatibility concerns with this change?

@aaronlehmann
Copy link
Collaborator Author

@tonistiigi: ping when you get a chance - don't want to break anything with this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants