Skip to content

Use linear matcher for string template literals - #6761

Merged
tim-smart merged 1 commit into
v3from
agent/codex-engineer/93d66baf
Jul 29, 2026
Merged

Use linear matcher for string template literals#6761
tim-smart merged 1 commit into
v3from
agent/codex-engineer/93d66baf

Conversation

@tim-smart

Copy link
Copy Markdown
Contributor

Summary

  • use a linear left-to-right matcher when every template literal span is exactly StringKeyword
  • retain the existing regex fallback for all other span types
  • add regex-equivalence coverage, an adversarial performance guard, and an effect patch changeset

Scope

  • Union spans containing StringKeyword remain on the existing regex path and are not optimized here.
  • getTemplateLiteralCapturingRegExp is untouched. TemplateLiteralParser still uses that capturing regex and may exhibit the same backtracking behavior.

Validation

  • pnpm lint-fix
  • pnpm test run packages/effect/test/Schema/Schema/TemplateLiteral/TemplateLiteral.test.ts
  • pnpm check
  • pnpm build
  • pnpm docgen

Closes EFF-209

@tim-smart
tim-smart requested a review from gcanti as a code owner July 29, 2026 23:29
@github-project-automation github-project-automation Bot moved this to Discussion Ongoing in PR Backlog Jul 29, 2026
@pullfrog

pullfrog Bot commented Jul 29, 2026

Copy link
Copy Markdown
Contributor
  • Checkout PR Use linear matcher for string template literals #6761 and read the diff
  • Triage: understand what the PR does and its domain
  • Specialist decision: identify unresolved questions
  • Dispatch specialists if needed
  • Aggregate findings & draft review
  • Submit review via pullfrog_create_pull_request_review

Pullfrog  | View workflow run | via Pullfrog | Using DeepSeek Pro (free via Pullfrog for OSS) (Kimi K2 not used — the program covers this model; add its provider key to run your pick) | 𝕏

@changeset-bot

changeset-bot Bot commented Jul 29, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: dce60f0

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
effect Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@effect-slopcop effect-slopcop Bot added 3.0 Used for issues, pull requests, etc. that are relevant for the `v3` branch targeting Effect v3. enhancement New feature or request labels Jul 29, 2026
@tim-smart
tim-smart enabled auto-merge (squash) July 29, 2026 23:32
@tim-smart
tim-smart merged commit 3cc3c6e into v3 Jul 29, 2026
9 checks passed
@tim-smart
tim-smart deleted the agent/codex-engineer/93d66baf branch July 29, 2026 23:34
@github-project-automation github-project-automation Bot moved this from Discussion Ongoing to Done in PR Backlog Jul 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3.0 Used for issues, pull requests, etc. that are relevant for the `v3` branch targeting Effect v3. enhancement New feature or request

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant