Releases: humbug/php-scoper
Releases · humbug/php-scoper
0.17.4
0.17.3
0.17.2
0.17.1
0.17.0
Features
- Improve PHP 8.1 support
- Add InspectSymbols command (#619)
- Add support for regexes for excluded symbols (#660)
Bugfixes
- Patch various symbols not interpreted as internal (#626)
- Stops the process if says no when PHP-Scoper asks if the output directory can be deleted (#631)
- Fix autoload generator links (#630)
Docs
- Document the idiomatic way to include polyfills (#636)
- Replace incorrect usage of
files-whitelist
byexclude-files
(#651)
Misc
- Move default file name to the ConfigurationFactory (#621)
- Prefer newline over writing empty string (#622)
- Improve tests(#624, #648, #654, #659)
- Move EnrichedReflector into a factory service (#625)
- Build the PHAR in multiple PHP versions for better testing (#628)
- Add
Configuration::withPrefix()
(#629) - Add outdated-fixtures command by (#641)
- Improve NamespaceRegistry (#645)
- Simplify TraverserFactory (#653)
- Introduce a Printer abstraction (#655)
- Adapt printer API to preserve formatting (#652)
0.16.2
0.16.1
0.16.0
Breaking Changes
files-whitelist
has been renamed intoexclude-files
whitelist-global-constants
has been renamed intoexpose-global-constants
whitelist-global-classes
has been renamed intoexpose-global-classes
whitelist-global-functions
has been renamed intoexpose-global-functions
whitelist
has been deprecated in favour of theexclude-*
andexpose-*
entries and will be removed in 0.17.0
Features
- Bump min PHP version to 7.4 (#474)
- Improve file whitelist (renamed excluded files) performances (#445)
- Rework the whole "whitelist" logic to split it into two concepts: exclude and expose. Excluded symbols are treated as PHP internal symbols i.e. left untouched. Exposed symbols are symbols that will remain accessible after scoping. More details in the docs and the following related PRs:
- Allow to register internal symbols & namespaces (#493, #494, #520, #570) via the config entries
exclude-{namespaces, constants, classes, functions}
- Rename the
whitelist-global-{constants, classes, functions}
toexpose-global-{constants, classes, functions}
(#517) - Move from
whitelist
toexpose-{namespaces, constants, classes, functions}
(#519, #521, #522, #525, #526, #527, #553, #608)
- Allow to register internal symbols & namespaces (#493, #494, #520, #570) via the config entries
- Change default expose global symbols from true to false (#523)
- Fix (some) PHP8.1 compatibility (#528)
- Remove Composer1 support (#544, #556)
- Add multi-const statement support (#571)
- Rename "whitelisted files" to "excluded files" (#611)
Bugfixes
- Fix polyfills shipped within PHP-Scoper (#481)
- Fix prefix validation (#490)
- Fix scoping of typed properties (#499)
- Fix scoping of NULL (#500)
- Fix scoping of closures return type (#524)
- Fix doc link (#531, #385)
- Fix regex detection (#596)
- Restrict regex delimiters allowed (#598)
Misc
- Various Makefile improvements (#476, #588)
- Various code improvements:
- Switch to the Safe API when possible (#475)
- Leverage PHP 7.4 (#478, #491)
- Integrate FidryConsole (#418)
- Validate the prefix in the Configuration instead of the command (#482)
- Refactor AddPrefixCommand (#483)
- Make prefix non-nullable (#485)
- Use self instead of this for PHPUnit assertions (#487)
- Move creation of the config into a dedicated factory class (#488)
- Move Prefix validation to the Configuration class (#489)
- Make PHPUnit data providers static (#518)
- Introduce ScoperFactory (#492)
- Refactor various classes (#495, #502, #503, #504, #505, #506, #507, #508, #509, #564, #566, #569, #573, #574, #578, #580, #576, #581, #585, #586, #587, #591, #592, #594, #602, #603, #604, #552)
- Replace PHP-Scoper name resolver by the PHP-Parser one (Part 1) (#496)
- Introduce static utility method for reflector (#554)
- Make methods static when possible (#558)
- Move the prefix, patchers and whitelist out of the Scoper interface (#555)
- Introduce a Patcher interface (#562)
- Introduce SymbolsRegistry (#567)
- Introduce the EnrichedReflector (#575)
- Introduce NamespaceRegistry (#582)
- Introduce SymbolsConfiguration (#584)
- Introduce SymbolRegistry (singular) (#593)
- Improve the CI (#544, #545, #546, #547, #550, #551, #560, #568)
- Update composer config to allow plugins (#561, #605)
- Fix Box (#590)
- Enrich spec failure message (#599)
- Update the doc (#610)