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

⚡✅ Update more regexps to run in linear time #147

Merged
merged 1 commit into from
Apr 29, 2023
Merged

Commits on Apr 28, 2023

  1. ⚡✅ Update all net-imap regexps to run in O(n)

    The BIDI_FAILURE regexps all used `\g<name>` to define char classes and
    then re-use them.  Unfortunately, ruby 3.2 can't compile that to run in
    linear time.  The regexps could also be written using lookahead, but
    that also wouldn't run in linear time.
    
    The debug output gsub is simple to accomplish without negative lookahead
    by using a block with gsub and checking `$'.empty?`.
    
    `bin/check-regexps` was added for quick double-check, just in case the
    tests aren't catching everything.
    nevans committed Apr 28, 2023
    Configuration menu
    Copy the full SHA
    59c72fd View commit details
    Browse the repository at this point in the history