Bug #67641 [NEW]: SoapFault Traversable ?
| From: | vosa at binaryparadise dot com | Date: | Thu, 17 Jul 2014 11:50:13 +0000 |
| Subject: | Bug #67641 [NEW]: SoapFault Traversable ? | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-186690@lists.php.net to get a copy of this message | ||
From: vosa at binaryparadise dot com
Operating system: debian
PHP version: Irrelevant
Package: SOAP related
Bug Type: Bug
Bug description:SoapFault Traversable ?
Description:
------------
---
From manual page: http://www.php.net/class.soapfault
---
There's strange behavior of SoapFault instance when used in foreach
construct. It behave almost like Transversable object, but it shouldn't.
SoapFault extends Exception and none of these classes implements
Transversable interface...
Test script:
---------------
print "Exception:\n";
foreach(new Exception('message') as $k => $v)
print "$k: $v\n";
print "SoapFault:\n";
foreach(new Soapfault('faultcode', 'faultstring') as $k => $v)
print "$k: $v\n";
Expected result:
----------------
Exception:
SoapFault:
Actual result:
--------------
Exception:
SoapFault:
faultstring: faultstring
faultcode: faultcode
--
Edit bug report at https://bugs.php.net/bug.php?id=67641&edit=1
--