Skip to content

Remove the ambiguity from the PostScript number regex - #21709

Merged
timvandermeij merged 1 commit into
mozilla:masterfrom
calixteman:postscript-number-regex
Aug 4, 2026
Merged

Remove the ambiguity from the PostScript number regex#21709
timvandermeij merged 1 commit into
mozilla:masterfrom
calixteman:postscript-number-regex

Conversation

@calixteman

Copy link
Copy Markdown
Contributor

\d+\.?\d* can split a run of digits in as many ways as it is long, so it would backtrack polynomially if anything following it could reject. The optional exponent can't, hence no bug today, but \d+(?:\.\d*)? accepts the same numbers unambiguously.

`\d+\.?\d*` can split a run of digits in as many ways as it is long, so
it would backtrack polynomially if anything following it could reject.
The optional exponent can't, hence no bug today, but `\d+(?:\.\d*)?`
accepts the same numbers unambiguously.
@calixteman calixteman added the core label Aug 4, 2026
@codecov-commenter

codecov-commenter commented Aug 4, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 90.02%. Comparing base (e57a464) to head (16f5691).

Additional details and impacted files
@@            Coverage Diff             @@
##           master   #21709      +/-   ##
==========================================
- Coverage   90.04%   90.02%   -0.02%     
==========================================
  Files         264      264              
  Lines       66894    66894              
==========================================
- Hits        60232    60220      -12     
- Misses       6662     6674      +12     
Flag Coverage Δ
browsertest 66.52% <100.00%> (+<0.01%) ⬆️
fonttest 9.03% <ø> (ø)
integrationtest 69.35% <100.00%> (-0.01%) ⬇️
unittest 57.88% <100.00%> (-0.01%) ⬇️
unittestcli 56.60% <100.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@timvandermeij
timvandermeij merged commit 729ddf9 into mozilla:master Aug 4, 2026
20 of 21 checks passed
@timvandermeij

Copy link
Copy Markdown
Collaborator

Preventing issues here seems like a good idea, so thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants