• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

loot / libloot / 16605032022

29 Jul 2025 05:25PM UTC coverage: 92.895% (-0.003%) from 92.898%
16605032022

push

github

Ortham
Switch to the regress crate for regex

It uses about 56 MB less memory when LOOT launches into my Skyrim SE
large test load order with the latest masterlist and prelude, and
explicitly targets ECMAScript-like syntax like C++ std::regex does,
though supports newer functionality.

Compared to fancy-regex's syntax support, regress adds support for the
\0 nul character escape and removes support for:

- modifiers (e.g. `(?i)`)
- some Unicode character classes (e.g. used with `\p{}` and `\P{}`)
- the ASCII/POSIX character classes (e.g. `[:alpha:]`)
- various character escapes, including \A \a \z \b{start} \<
  \b{end} \> \b{start-half} \b{end-half}
- (?P<name>exp) named capture groups

However, since regress's v flag requires more characters to be escaped
inside character classes than fancy-regex's Unicode support requires,
it's not used, so that further restricts the supported Unicode character
classes, and means that character class intersection, union and
subtraction syntaxes aren't supported.

The nul character escape is irrelevant for filename matching as it's not
allowed in Windows or Linux filenames.

Compared to C++ std::regex, the new restrictions are:

- the lack of support for ASCII/POSIX character classes
- the lack of support for control character escapes (e.g. `\cX`)

The lack of support for control character escapes is irrelevant as
control characters aren't allowed in Windows filenames.

A search of the masterlists doesn't find any use of the ASCII character
classes, and it's very unlikely that any user metadata would use them.
If such syntax is in use, it'll cause an error.

35 of 37 new or added lines in 3 files covered. (94.59%)

10655 of 11470 relevant lines covered (92.89%)

217.08 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

97.61
/src/plugin/mod.rs


Source Not Available

STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc