PHPackages                             phuture/continuum - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. phuture/continuum

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

phuture/continuum
=================

A forward-compatibility layer bringing tomorrow’s PHP features to today’s runtimes.

v0.1.5(1mo ago)0781MITPHPPHP ^8.0CI passing

Since Apr 1Pushed 1mo agoCompare

[ Source](https://github.com/phuture-dev/continuum)[ Packagist](https://packagist.org/packages/phuture/continuum)[ RSS](/packages/phuture-continuum/feed)WikiDiscussions main Synced 4w ago

READMEChangelog (6)Dependencies (79)Versions (9)Used By (1)

Phuture Continuum
=================

[](#phuture-continuum)

**A forward-compatibility layer bringing tomorrow’s PHP features to today’s runtimes.**

[![PHP Version](https://camo.githubusercontent.com/6a08823a3a770b3a6a8b894edf3af6286e155bb6ee7380347718d2f065e5b98b/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f64796e616d69632f6a736f6e3f75726c3d68747470732533412532462532467261772e67697468756275736572636f6e74656e742e636f6d253246706875747572652d646576253246636f6e74696e75756d2532467265667325324668656164732532466d61696e253246636f6d706f7365722e6a736f6e2671756572793d726571756972652e706870267374796c653d666f722d7468652d6261646765266c6162656c3d50485025323056657273696f6e26636f6c6f723d707572706c65)](https://camo.githubusercontent.com/6a08823a3a770b3a6a8b894edf3af6286e155bb6ee7380347718d2f065e5b98b/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f64796e616d69632f6a736f6e3f75726c3d68747470732533412532462532467261772e67697468756275736572636f6e74656e742e636f6d253246706875747572652d646576253246636f6e74696e75756d2532467265667325324668656164732532466d61696e253246636f6d706f7365722e6a736f6e2671756572793d726571756972652e706870267374796c653d666f722d7468652d6261646765266c6162656c3d50485025323056657273696f6e26636f6c6f723d707572706c65)[![Latest Release](https://camo.githubusercontent.com/ad42f29b788e00cb2875706057f24e897b511f653b9144f5bb998426a62e762a/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f762f7461672f706875747572652d6465762f636f6e74696e75756d3f736f72743d73656d766572267374796c653d666f722d7468652d6261646765266c6162656c3d6c617465737425323072656c6561736526636f6c6f723d626c7565)](https://camo.githubusercontent.com/ad42f29b788e00cb2875706057f24e897b511f653b9144f5bb998426a62e762a/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f762f7461672f706875747572652d6465762f636f6e74696e75756d3f736f72743d73656d766572267374796c653d666f722d7468652d6261646765266c6162656c3d6c617465737425323072656c6561736526636f6c6f723d626c7565)[![Tests Status](https://camo.githubusercontent.com/e0e7821f3127322bfa7a4185f0b8d4ec525f92155a065b526554b0d5334e6733/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f706875747572652d6465762f636f6e74696e75756d2f74657374732e796d6c3f7374796c653d666f722d7468652d6261646765266c6162656c3d7465737473)](https://camo.githubusercontent.com/e0e7821f3127322bfa7a4185f0b8d4ec525f92155a065b526554b0d5334e6733/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f706875747572652d6465762f636f6e74696e75756d2f74657374732e796d6c3f7374796c653d666f722d7468652d6261646765266c6162656c3d7465737473)[![License](https://camo.githubusercontent.com/05d20b54aaf4411f736110c588a3e2f13da70c6fa0cf9e6e72f78f6504891abc/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f706875747572652d6465762f636f6e74696e75756d3f7374796c653d666f722d7468652d6261646765)](https://camo.githubusercontent.com/05d20b54aaf4411f736110c588a3e2f13da70c6fa0cf9e6e72f78f6504891abc/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f706875747572652d6465762f636f6e74696e75756d3f7374796c653d666f722d7468652d6261646765)

Introduction
------------

[](#introduction)

**Continuum** bridges the gap between PHP versions by extending [Symfony Polyfill](https://github.com/symfony/polyfill) with additional methods, constants, and stubs. Built on Symfony's solid foundation, Continuum provides extra polyfills and graceful fallbacks—enabling you to write forward-compatible code that works consistently across different PHP runtimes.

Features
--------

[](#features)

This package polyfills most common PHP functions from PHP 8.1 to 8.5, designed to be used on PHP 8.0 or later.

PolyfillLevelType▶️ **PHP 8.1+**`array_is_list()`✅ FullFunction`enum_exists()`✅ FullFunction`fsync()`❇️ PartialFunction`fdatasync()`❇️ PartialFunction`IMAGETYPE_AVIF`✅ FullConstant`IMG_AVIF`✅ FullConstant`IMG_WEBP_LOSSLESS`✅ FullConstant`MYSQLI_REFRESH_REPLICA`✅ FullConstant`T_READONLY`✅ FullConstant`CURLStringFile`✅ FullClass`ReturnTypeWillChange`✅ FullAttribute▶️ **PHP 8.2+**`ini_parse_quantity()`✅ FullFunction`odbc_connection_string_is_quoted()`✅ FullFunction`odbc_connection_string_should_quote()`✅ FullFunction`odbc_connection_string_quote()`✅ FullFunction`curl_upkeep()`❇️ PartialFunction`memory_reset_peak_usage()`⚠️ No-opFunction`mysqli_execute_query()`✅ FullFunction`openssl_cipher_key_length()`✅ FullFunction`imap_is_open()`✅ FullFunction`AllowDynamicProperties`✅ FullAttribute`SensitiveParameter`✅ FullAttribute`SensitiveParameterValue`✅ FullClass`Random\Engine`✅ FullInterface`Random\CryptoSafeEngine`✅ FullInterface`Random\Engine\Secure`✅ FullClass▶️ **PHP 8.3+**`json_validate()`✅ FullFunction`mb_str_pad()`✅ FullFunction`str_increment()`✅ FullFunction`str_decrement()`✅ FullFunction`stream_context_set_options()`✅ FullFunction`posix_eaccess()`✅ FullFunction`POSIX_PC_*` (10 constants)✅ FullConstant`POSIX_*_OK` (4 constants)✅ FullConstant`Override`✅ FullAttribute`DateError` / `DateException` (and related)✅ FullClass`SQLite3Exception`✅ FullClass`ldap_exop_sync()`✅ FullFunction`ldap_connect_wallet()`✅ FullFunction▶️ **PHP 8.4+**`array_find()`✅ FullFunction`array_find_key()`✅ FullFunction`array_any()`✅ FullFunction`array_all()`✅ FullFunction`fpow()`✅ FullFunction`grapheme_str_split()`✅ FullFunction`PHP_SBINDIR`✅ FullConstant`CURL_HTTP_VERSION_3`✅ FullConstant`CURL_HTTP_VERSION_3ONLY`✅ FullConstant`Deprecated`✅ FullAttribute`RoundingMode`✅ FullEnum`ReflectionConstant`✅ FullClass`PDO` driver subclasses (Dblib, Firebird, etc.)✅ FullClass▶️ **PHP 8.5+**`array_first()`✅ FullFunction`array_last()`✅ FullFunction`get_error_handler()`✅ FullFunction`get_exception_handler()`✅ FullFunction`locale_is_right_to_left()`✅ FullFunction`grapheme_levenshtein()`✅ FullFunction`PHP_BUILD_DATE`✅ FullConstant`PHP_BUILD_PROVIDER`✅ FullConstant`NoDiscard`✅ FullAttribute`DelayedTargetValidation`✅ FullAttribute`Uri\Rfc3986\Uri`✅ FullClass`Uri\WhatWg\Url`✅ FullClass`Uri\WhatWg\InvalidUrlException`✅ FullClass`Uri\WhatWg\UrlValidationError`✅ FullClass`Uri\WhatWg\UrlValidationErrorType`✅ FullClass`Uri\UriException`✅ FullClass`Uri\InvalidUriException`✅ FullClass`Uri\UriComparisonMode`✅ FullClass`Filter\FilterException`✅ FullClass`Filter\FilterFailedException`✅ FullClassThis package also provides polyfills for some PHP extensions, allowing better portability across different PHP runtimes.

ExtensionLevel`ext-mbstring`⚠️ Partial`ext-iconv`✅ Full`ext-apcu`⚠️ Partial`ext-ctype`✅ Full`ext-uuid`✅ Full`ext-bcmath`✅ Full`ext-intl`⚠️ Partial`ext-zip`⚠️ PartialWhat's Not Covered
------------------

[](#whats-not-covered)

The entries marked ❇️ Partial or ⚠️ Partial in the tables above have meaningful gaps. This section documents exactly what each one omits or cannot replicate.

### Partial Polyfills

[](#partial-polyfills)

**`fsync()` / `fdatasync()`** (PHP 8.1)

- Both fall back to `fflush()`, plus `posix_fsync()` when the `posix` extension is loaded.
- There is no guarantee of actual disk-level synchronization on systems without the POSIX extension.
- The return value is always `true`, even when the underlying OS sync did not occur.

**`curl_upkeep()`** (PHP 8.2)

- Only sets `CURLOPT_FORBID_REUSE = false` and `CURLOPT_FRESH_CONNECT = false`.
- Does not perform real HTTP/2 connection maintenance (window-size updates, PING frames, or keep-alive signalling).
- Full behaviour requires PHP 8.2+ with libcurl ≥ 7.62.0.

### Partial Extensions

[](#partial-extensions)

**`ext-mbstring`**

- The only functions with **no polyfill** are the stateful regex-search family: `mb_ereg_search()`, `mb_ereg_search_init()`, `mb_ereg_search_pos()`, `mb_ereg_search_regs()`, `mb_ereg_search_getpos()`, `mb_ereg_search_getregs()`, and `mb_ereg_search_setpos()`.
- `mb_convert_kana()` supports only the `R`, `r`, `N`, `n`, `K`, `k`, `V`, `A`, `a` conversion modes.

**`ext-apcu`**

- In-memory, non-persistent cache: data is lost between requests.
- Scoped to a single process; entries are not shared across PHP-FPM workers.
- No atomic operations beyond basic `get`/`set`; no TTL-based eviction or shared-memory sizing.

**`ext-intl`**

- `Collator`: simplified sorting - does not implement the full Unicode Collation Algorithm.
- `NumberFormatter`: advanced formatting features (currency symbol overrides, padding, significant digits) are missing.
- `Locale`: operations are simplified; no full CLDR data lookup.
- No direct access to ICU binary data; limited to the subset bundled with Symfony.

**`ext-zip`**

- `ZipArchive::getArchiveFlag()` - always returns `0`; archive-level flags are a libzip internal concept not accessible through userland php.
- `ZipArchive::setArchiveFlag()` - always returns `false`.
- `ZipArchive::registerProgressCallback()` - always returns `false`.
- `ZipArchive::registerCancelCallback()` - always returns `false`.
- Procedural `zip_entry_open()` only accepts modes `r` and `rb`; write-mode entry access is not supported.
- Multi-disk ZIP archives are not supported.
- Writing with compression methods `CM_LZMA`, `CM_LZMA2`, and `CM_XZ` is not supported.

Installation
------------

[](#installation)

```
composer require phuture/continuum
```

Contributing
------------

[](#contributing)

Thank you for considering contributing to this project! You can read the **[Contribution Guide](CONTRIBUTING.md)** and our **[Developer Workflow Guide](WORKFLOW.md)**.

Code of Conduct
---------------

[](#code-of-conduct)

This project follows a Code of Conduct that all community members and contributors are expected to adhere to our **[Contributor Code of Conduct](CODE_OF_CONDUCT.md)**.

License
-------

[](#license)

This project is open-source and available under the **MIT License**.

###  Health Score

39

—

LowBetter than 85% of packages

Maintenance94

Actively maintained with recent releases

Popularity13

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity34

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~11 days

Total

6

Last Release

33d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/8017d1124ddecbb0822ee96a1860de7386b23f6f7151007ccb79c92bc4b83416?d=identicon)[phuture](/maintainers/phuture)

---

Top Contributors

[![abdyfranco](https://avatars.githubusercontent.com/u/23648083?v=4)](https://github.com/abdyfranco "abdyfranco (10 commits)")

---

Tags

compatibilityportablepolyfillshim

###  Code Quality

Static AnalysisPHPStan

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/phuture-continuum/health.svg)

```
[![Health](https://phpackages.com/badges/phuture-continuum/health.svg)](https://phpackages.com/packages/phuture-continuum)
```

###  Alternatives

[symfony/symfony

The Symfony PHP framework

31.4k87.2M2.2k](/packages/symfony-symfony)[drupal/core-recommended

Locked core dependencies; require this project INSTEAD OF drupal/core.

6942.5M405](/packages/drupal-core-recommended)[civicrm/civicrm-core

Open source constituent relationship management for non-profits, NGOs and advocacy organizations.

751291.4k38](/packages/civicrm-civicrm-core)[symfony/string

Provides an object-oriented API to strings and deals with bytes, UTF-8 code points and grapheme clusters in a unified way

1.8k777.3M1.2k](/packages/symfony-string)[friendsofphp/php-cs-fixer

A tool to automatically fix PHP code style

13.5k251.2M24.4k](/packages/friendsofphp-php-cs-fixer)[sylius/sylius

E-Commerce platform for PHP, based on Symfony framework.

8.5k5.9M721](/packages/sylius-sylius)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
