Decrease processing time of rules, fixes #1665 #1708 #1791
Merged
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.
This PR fixes the #1665, which created in old repository, and the migration bot copied here. Later @fzipi created a reminder.
In the old repo, there was a fix with so many comments. @allanrbo and @mirkodziadzka-avi found two similar solutions. I made a tool to make some comparisons for performance. I found that the first solution from Allan gives better performance, but we stayed in we keep the more clear solutions.
The diff is a bit different than the original pull request. I assume Allan assembled the regexes (from the data files) with regex-assemble.pl, not the regexp-assemble-v2.pl, and we didn't realized that some regression tests were failed.
Now I assembled the data files with regex-assemble-v2.pl, and appended the
(?i:
modifier. Now all regression test were passed.Hope we can merge this PR before the release of v3.3.
Credits are for @allanrbo and @mirkodziadzka-avi. Thanks for all participants.