[PHP-BUG] Bug #72718 [NEW]: PHP7: array to string conversion
[email protected] ("spam2 at rhsoft dot net") Sun, 31 Jul 2016 10:08:52 GMT
| Newsgroups | php.standards |
|---|---|
| Message-ID | <[email protected]> |
From: spam2 at rhsoft dot net
Operating system:
PHP version: 7.0.9
Package: PHP Language Specification
Bug Type: Bug
Bug description:PHP7: array to string conversion
Description:
------------
$count = $GLOBALS['cl_api']->$module['api_name']->count(0);
$count = $GLOBALS['cl_api']->{$module['api_name']}->count(0);
why in the world is the first a "array to string conversion" with PHP7
$module['api_name'] is clearly a field of a array and a string
while i suck all the changes in context of $$ that above is somehow
unacceptable because there is hardly some clean way to seek for such
things since seek for ]-> would also find any of similar but fine code
and seek for ]->$ the same
--
Edit bug report at https://bugs.php.net/bug.php?id=72718&edit=1
--
Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=72718&r=trysnapshot54
Try a snapshot (PHP 5.5): https://bugs.php.net/fix.php?id=72718&r=trysnapshot55
Try a snapshot (trunk): https://bugs.php.net/fix.php?id=72718&r=trysnapshottrunk
Fixed in SVN: https://bugs.php.net/fix.php?id=72718&r=fixed
Fixed in release: https://bugs.php.net/fix.php?id=72718&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=72718&r=needtrace
Need Reproduce Script: https://bugs.php.net/fix.php?id=72718&r=needscript
Try newer version: https://bugs.php.net/fix.php?id=72718&r=oldversion
Not developer issue: https://bugs.php.net/fix.php?id=72718&r=support
Expected behavior: https://bugs.php.net/fix.php?id=72718&r=notwrong
Not enough info: https://bugs.php.net/fix.php?id=72718&r=notenoughinfo
Submitted twice: https://bugs.php.net/fix.php?id=72718&r=submittedtwice
register_globals: https://bugs.php.net/fix.php?id=72718&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=72718&r=php4
Daylight Savings: https://bugs.php.net/fix.php?id=72718&r=dst
IIS Stability: https://bugs.php.net/fix.php?id=72718&r=isapi
Install GNU Sed: https://bugs.php.net/fix.php?id=72718&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=72718&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=72718&r=nozend
MySQL Configuration Error: https://bugs.php.net/fix.php?id=72718&r=mysqlcfg