Replace lazy_static with std::sync::LazyLock#306
Replace lazy_static with std::sync::LazyLock#306jbgriesner wants to merge 2 commits intortk-ai:masterfrom
Conversation
|
Hi @jbgriesner, the migration is mechanically correct across all 14 files and the motivation is solid: one fewer external dependency, aligned with the standard library since Rust 1.80. Two things needed before merge:
Minor note: |
|
Hey @jbgriesner, heads up: PR #349 (TOML filter DSL) uses |
- Add rust-version = "1.80" to Cargo.toml: LazyLock was stabilized in Rust 1.80, this gives a clear error instead of cryptic compile failure on older toolchains - Move LazyLock statics in next_cmd.rs and playwright_cmd.rs from function bodies to module level, consistent with every other module in the codebase - Remove unused ROUTE_PATTERN static (dead code cleanup) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
0cae53d to
f8d090a
Compare
The 0/0 CI checks are a GitHub limitation with fork PRs: workflows run from the fork's own .github/workflows/ directory, not from the upstream repo. Since my fork doesn't replicate the upstream CI setup, no checks trigger automatically. I've verified locally that all three gates pass: cargo fmt --all && cargo clippy --all-targets && cargo test |
Replaces all uses of the
lazy_staticcrate withstd::sync::LazyLock, which has been stable since Rust 1.80.Motivation:
lazy_static = "1.4")No behavior change. LazyLock initializes on first access, exactly like lazy_static. All regex patterns remain identical.