PHPackages                             gisostallenberg/php-to-7-aid - 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. gisostallenberg/php-to-7-aid

Abandoned → [sstalle/php7cc](/?search=sstalle%2Fphp7cc)ArchivedLibrary[Utility &amp; Helpers](/categories/utility)

gisostallenberg/php-to-7-aid
============================

Tool to find and possibly fix backward incompatible changes in your existing codebase when upgrading to or preparing for PHP7

0.0.0(10y ago)413.3k↓33.3%8[1 issues](https://github.com/gisostallenberg/php-to-7-aid/issues)MITPHPPHP ^5.3.6||7.0.\*

Since Jun 30Pushed 10y ago5 watchersCompare

[ Source](https://github.com/gisostallenberg/php-to-7-aid)[ Packagist](https://packagist.org/packages/gisostallenberg/php-to-7-aid)[ RSS](/packages/gisostallenberg-php-to-7-aid/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (3)Versions (2)Used By (0)

phpTo7aid
=========

[](#phpto7aid)

Tool to find, and possibly fix, backward incompatible changes in your existing codebase when upgrading to or preparing for PHP7

About
-----

[](#about)

The goal of phpTo7aid is to identify PHP 5 code that will not work in PHP 7. It tries to aid you as much as possible in resolving this issues, by either providing the exact solution or giving hints on how to solve the issue.

##### Status

[](#status)

Please note that this version is still in development. See Versioning below or SemVer: "Major version zero (0.y.z) is for initial development. Anything may change at any time. The public API should not be considered stable."

##### Versioning

[](#versioning)

phpTo7aid uses [Semantic Versioning 2](http://semver.org/) as guideline for new versions.

##### License

[](#license)

phpTo7aid is licensed under the MIT License - see the `LICENSE` file for details.

##### Authors

[](#authors)

[Giso Stallenberg](https://github.com/gisostallenberg/)

##### Installing

[](#installing)

Using [composer](https://getcomposer.org/download/).

`composer require gisostallenberg/php-to-7-aid`

Run directly

`wget https://github.com/gisostallenberg/php-to-7-aid/raw/master/php-to-7-aid.phar -O php-to-7-aid.phar; php php-to-7-aid.phar run`

##### Backward Incompatible Changes in PHP 7

[](#backward-incompatible-changes-in-php-7)

See [PHP 7 UPGRADING](https://github.com/php/php-src/blob/php-7.0.0alpha2/UPGRADING)

###### Implemented

[](#implemented)

###### Will not be implemented (including reason)

[](#will-not-be-implemented-including-reason)

###### Not yet implemented

[](#not-yet-implemented)

- Indirect variable, property and method references are now interpreted with left-to-right semantics.
- The global keyword now only accepts simple variables
- Parentheses around variables or function calls no longer have any influence on behavior
- Array elements or object properties that are automatically created during by-reference assignments will now result in a different order
- list() will no longer assign variables in reverse order
- Empty list() assignments are no longer allowed
- list() no longer supports unpacking strings
- Iteration with foreach() no longer has any effect on the internal array pointer
- When iterating arrays by-value, foreach will now always operate on a copy of the array, as such changes to the array during iteration will not influence iteration behavior
- When iterating arrays by-reference, modifications to the array will continue to influence the iteration.
- Iteration of plain (non-Traversable) objects by-value or by-reference will behave like by-reference iteration of arrays
- It is no longer possible to define two function parameters with the same name.
- The func\_get\_arg() and func\_get\_args() functions will no longer return the original value that was passed to a parameter and will instead provide the current value (which might have been modified).
- Exception backtraces will no longer display the original value that was passed to a function and show the modified value instead
- Invalid octal literals (containing digits larger than 7) now produce compile errors.
- Bitwise shifts by negative numbers will now throw a warning and return false
- Left bitwise shifts by a number of bits beyond the bit width of an integer will always result in 0
- Right bitwise shifts by a number of bits beyond the bit width of an integer will always result in 0 or -1 (depending on sign)
- Strings that contain hexadecimal numbers are no longer considered to be numeric and don't receive special treatment anymore.
- Due to the addition of the Unicode Codepoint Escape Syntax for double-quoted strings and heredocs, "\\u{" followed by an invalid sequence will now result in an error
- There are now two exception classes: Exception and Error. Both classes implement a new interface Throwable.
- Some fatal errors and recoverable fatal errors now throw an Error instead
- Parser errors now generate a ParseError that extends Error
- Constructors of internal classes will now always throw an exception on failure
- The error level of some E\_STRICT notices has been changed
- Removed support for static calls to non-static calls form an incompatible $this context.
- It is no longer possible to use the following class, interface and trait names (case-insensitive): bool, int, float, string, null, false, true
- The following class, interface and trait names are now reserved for future use, but do not yet throw an error when used: resource, object, mixed, numeric
- The yield language construct no longer requires parentheses when used in an expression context
- Removed ASP (&lt;%) and script (&lt;script language=php&gt;) tags
- Removed support for assigning the result of new by reference\* Removed support for scoped calls to non-static methods from an incompatible $this context
- Removed support for #-style comments in ini files
- $HTTP\_RAW\_POST\_DATA is no longer available
- call\_user\_method() and call\_user\_method\_array() no longer exists
- ob\_start() no longer issues an E\_ERROR, but instead an E\_RECOVERABLE\_ERROR in case an output buffer is created in an output buffer handler
- Improved zend\_qsort(using hybrid sorting algo) for better performance, and also renamed zend\_qsort to zend\_sort.
- Added stable sorting algo zend\_insert\_sort
- Removed dl() function on fpm-fcgi
- setcookie() with an empty cookie name now issues a WARNING and doesn't send an empty set-cookie header line anymore
- Removed support for disabling the CURLOPT\_SAFE\_UPLOAD option. All curl file uploads must use the curl\_file / CURLFile APIs
- Removed $is\_dst parameter from mktime() and gmmktime()
- dba\_delete() now returns false if the key was not found for the inifile handler, too.
- GMP requires libgmp version 4.2 or newer now
- gmp\_setbit() and gmp\_clrbit() now return FALSE for negative indices, making them consistent with other GMP functions
- Removed deprecated aliases datefmt\_set\_timezone\_id() and IntlDateFormatter::setTimeZoneID().
- Added LIBXML\_BIGLINES parser option
- Removed deprecated mcrypt\_generic\_end() alias in favor of mcrypt\_generic\_deinit()
- Removed deprecated mcrypt\_ecb(), mcrypt\_cbc(), mcrypt\_cfb() and mcrypt\_ofb() functions in favor of mcrypt\_encrypt() and mcrypt\_decrypt() with an MCRYPT\_MODE\_\* flag
- session\_start() accepts all INI settings as array. e.g. \['cache\_limiter'=&gt;'private'\] sets session.cache\_limiter=private. It also supports 'read\_and\_close' which closes session data immediately after read data
- Save handler accepts validate\_sid(), update\_timestamp() which validates session ID existence, updates timestamp of session data
- SessionUpdateTimestampHandlerInterface is added. validateSid(), updateTimestamp() is defined in the interface.
- session.lazy\_write(default=On) INI setting enables only write session data when session data is updated.
- Removed opcache.load\_comments configuration directive
- Removed the "rsa\_key\_size" SSL context option in favor of automatically setting the appropriate size given the negotiated crypto algorithm
- Removed "CN\_match" and "SNI\_server\_name" SSL context options.
- Removed support for /e (PREG\_REPLACE\_EVAL) modifier
- Removed PGSQL\_ATTR\_DISABLE\_NATIVE\_PREPARED\_STATEMENT attribute in favor of ATTR\_EMULATE\_PREPARES
- Removed string category support in setlocale()
- Removed set\_magic\_quotes\_runtime() and its alias magic\_quotes\_runtime()
- Rejected RFC 7159 incompatible number formats in json\_decode string - top level (07, 0xff, .1, -.1) and all levels (\[1.\], \[1.e1\])
- Calling json\_decode with 1st argument equal to empty PHP string or value that after casting to string is empty string (NULL, FALSE) results in JSON syntax error
- Removed set\_socket\_blocking() in favor of its alias stream\_set\_blocking()
- Removed xsl.security\_prefs ini option. Use XsltProcessor::setSecurityPrefs() instead

###  Health Score

31

—

LowBetter than 68% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity33

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity48

Maturing project, gaining track record

 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

Unknown

Total

1

Last Release

3975d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/1ea7c6acad608c13a090d72dc45f02ef149d8e41b16c671ee221baf7d1e977d7?d=identicon)[gisostallenberg](/maintainers/gisostallenberg)

---

Top Contributors

[![gisostallenberg](https://avatars.githubusercontent.com/u/11526270?v=4)](https://github.com/gisostallenberg "gisostallenberg (35 commits)")

### Embed Badge

![Health badge](/badges/gisostallenberg-php-to-7-aid/health.svg)

```
[![Health](https://phpackages.com/badges/gisostallenberg-php-to-7-aid/health.svg)](https://phpackages.com/packages/gisostallenberg-php-to-7-aid)
```

###  Alternatives

[symfony/maker-bundle

Symfony Maker helps you create empty commands, controllers, form classes, tests and more so you can forget about writing boilerplate code.

3.4k111.1M568](/packages/symfony-maker-bundle)[symplify/monorepo-builder

Not only Composer tools to build a Monorepo.

5205.3M82](/packages/symplify-monorepo-builder)[coenjacobs/mozart

Composes all dependencies as a package inside a WordPress plugin

4723.6M20](/packages/coenjacobs-mozart)[friendsoftypo3/content-blocks

TYPO3 CMS Content Blocks - Content Types API | Define reusable components via YAML

96374.6k23](/packages/friendsoftypo3-content-blocks)[shyim/danger-php

Port of danger to PHP

8544.9k](/packages/shyim-danger-php)[aedart/athenaeum

Athenaeum is a mono repository; a collection of various PHP packages

245.2k](/packages/aedart-athenaeum)

PHPackages © 2026

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