Exlcuding global namespace on versions >=0.18.0 #1140
Replies: 1 comment 4 replies
-
|
Uff a bit hard to recall exactly! I vaguely remember it was related to polyfills to support them without any extra work. I remember clearly the case for the functions, but I can't recall for classes.
Which should be fine: the alias shouldn't cause any failure does it?
The alias statement doesn't prevent the exclusion does it? Note that https://github.com/humbug/php-scoper/releases/tag/0.18.0-rc.0 global symbols are now exposed default. Edit: I see that you set it to false though so should not matter. As a rule of thumb:
|
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
I have a project where I use PHP-Scoper to isolate dependencies. Initially, PHP-Scoper was added when it was on version 0.17.5. Now I’m trying to update PHP-Scoper to 0.18.18 and have some questions about the results.
My
scoper.inc.phplooks like this:As an example, I have a file in my project with the following content:
With PHP-Scoper
0.18.18, I get that file processed as follows:The only difference compared to the result of PHP-Scoper
0.17.5is theclass_alias()call.This is probably expected because of this:
1a30d98#diff-c411ff3325ee021026ca5314ce27ee16e29049575e909fe1a4a924340bab39b2R84-R89
But I don’t quite understand the idea of how this should work. Could you please help me with this?
In my case, it seems I don’t have a declaration for the prefixed version, and the alias just doesn’t work.
Is the exclusion of the global namespace no longer allowed since 0.18.0?
Beta Was this translation helpful? Give feedback.
All reactions