Closed timbray closed 3 months ago
:warning: Please install the to ensure uploads and comments are reliably processed by Codecov.
Attention: Patch coverage is 86.95652%
with 6 lines
in your changes missing coverage. Please review.
Project coverage is 96.48%. Comparing base (
ec60e13
) to head (21975ae
).
Files | Patch % | Lines |
---|---|---|
field_matcher.go | 42.85% | 2 Missing and 2 partials :warning: |
nfa.go | 77.77% | 2 Missing :warning: |
:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
This adds the function
analyze()
to coreMatcher. It visits all of the fieldMatcher and valueMatcher states and gathers statistics (at the moment, just the maximum nondeterministic concurrency). For the moment, this is strictly an (extremely useful) tool for developers trying to optimize NFA construction/traversal.Its output could be used in practice to increase the performance of the pathological case illustrated by
TestShellStyleBuildTime()
, which slows down to <10K/second when you add 13K wildcard patterns, but that particular optimization requires much more thinking.No public API yet, but this could evolve into something similar to Ruler's
MachineComplexityEvaluator
public API although I'm not happy with the metric that API generates.Also in this commit: Miscellaneous code cleanups including fixing a new lint problem detected by recent
golangci-lint
, and restoring tests that had been commented out because of the NFA state explosion.