Skip to content

Stdlib: IntlDatePatternGenerator create/getBestPattern (#20740) - #20819

Merged
PurHur merged 1 commit into
masterfrom
fix/20740-intl-date-pattern-generator
Jul 19, 2026
Merged

PurHur merged 1 commit into
masterfrom
fix/20740-intl-date-pattern-generator

Conversation

@PurHur

@PurHur PurHur commented Jul 19, 2026

Copy link
Copy Markdown
Owner

Summary

  • New VmIntlDatePatternGenerator (create / __construct / getBestPattern) registered with IntlDateFormatter.
  • ICU udatpg_* FFI when libicui18n is present; static en_US/de_DE fallback otherwise.
  • Compliance .phpt + issue repro. No new runtime/ C.

Closes #20740

Test plan

  • PHP_COMPILER_PROFILE=8.4 php bin/vm.php test/repro/issue_20740_intl_date_pattern_generator.php
    true
    MMM d, y
    M/d/y
    d. MMM y
    
  • vendor/bin/phpunit --filter intl_date_pattern_generator → OK (2 tests, VM+JIT, 3×)
  • php script/bootstrap-inventory.php --check → OK
  • ./script/check-generated-docs.sh → in sync

php-src-strict; no php-compiler-strict shortcut.

Made with Cursor

Add PHP 8.1+ IntlDatePatternGenerator via ICU udatpg_* FFI with a small
CLDR fallback table so skeleton→pattern lookup works under PROFILE=8.4.

Co-authored-by: Cursor <cursoragent@cursor.com>
@PurHur
PurHur merged commit b2a7d1e into master Jul 19, 2026
1 check failed
@PurHur
PurHur deleted the fix/20740-intl-date-pattern-generator branch July 19, 2026 03:42
PurHur added a commit that referenced this pull request Jul 19, 2026
…20819 (#10533) (#20831)

Restore 5853/5853 spine coverage and gen-0 sidecar stamp so north-star5-fast and user_release_ready stay green after formatObject / DatePatternGenerator landed without spine requires.

Co-authored-by: PurHur <PurHur@users.noreply.github.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Stdlib: IntlDatePatternGenerator::create()/getBestPattern() missing (ext/intl/dateformat, PHP 8.1+)

1 participant