Skip to content

improve arkregex \d inference - #1564

Merged
ssalbdivad merged 2 commits into
mainfrom
arkregex-number
Dec 13, 2025
Merged

ssalbdivad merged 2 commits into
mainfrom
arkregex-number

Conversation

@ssalbdivad

Copy link
Copy Markdown
Member

represent \d as ${number} instead of ${bigint}

Though this slightly widens the scope of literal strings allowed by \d, it will now behave consistently and can collapse when multiple ${number}s appear in sequence, since ${number} allows 0-prefixed strings like "00" that are rejected by ${bigint}.

// was: Regex<`${bigint}${bigint}`>
// now: Regex<`${number}`>
regex("^\\d{2}$")

@ssalbdivad
ssalbdivad merged commit 5f9ddd7 into main Dec 13, 2025
6 checks passed
@ssalbdivad
ssalbdivad deleted the arkregex-number branch December 13, 2025 04:36
@github-project-automation github-project-automation Bot moved this from To do to Done (merged or closed) in arktypeio Dec 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done (merged or closed)

Development

Successfully merging this pull request may close these issues.

1 participant