rust-lang/regex

An implementation of regular expressions for Rust. This implementation uses finite automata and guarantees linear time matching on all inputs.

View on GitHub ↗Jump to charts ↓Open shareable report

Summary Information

Updated 16 minutes ago
Added to GitGenius on September 17th, 2026
Created on December 11th, 2014
Open Issues & Pull Requests: 82 (+0)
GitHub issues: Enabled
Number of forks: 534
Total Stargazers: 4,030 (+0)
Total Subscribers: 44 (+0)

Repository Insights (GitGenius)

Median issue/PR response: 0.8 hours
Mean response time: 38.6 days
90th percentile: 89.6 days
Tracked items: 65

Most active contributors

Sign in to see contributor activity.

How this project is maintained

84% of open issues come from outside the core team, so the backlog reflects real-world use rather than internal planning. Three people close 89% of everything that gets resolved.

Charts & Analytics

Fetching additional details & charts...

Issue Activity (beta)

Open issues: 31
New in 7 days: 0
Closed in 7 days: 0
Avg open age: 409 days
Stale 30+ days: 25
Stale 90+ days: 19

Recent activity

Opened in 7 days: 0
Closed in 7 days: 0
Comments in 7 days: 0
Events in 7 days: 0

Top labels

  • enhancement (12)
  • question (12)
  • bug (6)
  • documentation (4)
  • invalid (3)
  • wontfix (3)
  • fix-incoming (2)
  • duplicate (1)

Most active issues this week

No issue events were indexed in the last 7 days.

Detailed Description

regex is a regular expression engine for Rust that uses finite automata to guarantee linear time matching on all inputs.

The project solves the problem of pattern matching in Rust by implementing a regex engine built on finite automata rather than backtracking approaches. This design choice ensures predictable performance: every input is processed in linear time relative to its length, eliminating the pathological cases that plague traditional regex engines. The implementation handles the full regex syntax while maintaining this performance guarantee through careful automaton construction and optimization.

Developers should choose this library if they need reliable regex performance without worst-case slowdowns on adversarial inputs. It suits any Rust project requiring pattern matching, from text processing to parsing, where performance predictability matters. The linear-time guarantee makes it particularly valuable in applications processing untrusted input or operating under strict latency constraints, where traditional regex engines might cause denial-of-service vulnerabilities through catastrophic backtracking.

The project maintains steady development activity with regular commits addressing bug fixes, performance improvements, and feature enhancements. Pull requests receive timely review and feedback from maintainers. The codebase demonstrates consistent attention to both correctness and optimization, with changes often accompanied by benchmarking and testing improvements. Documentation is actively maintained to reflect the current state of the implementation.