Re: Re: [PATCH] Notice on array to string convertion
| From: | Jordi Boggiano | Date: | Sun, 30 Oct 2011 12:26:39 +0000 |
| Subject: | Re: Re: [PATCH] Notice on array to string convertion | ||
| References: | 1 2 3 4 5 6 7 8 9 10 11 12 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-55993@lists.php.net to get a copy of this message | ||
On 30.10.2011 13:19, Laruence wrote:
> Hi:
> like the following script:
> <?php
> $str = (string)array();
> echo $str;
>
> it is obviously intentionally convert a array to string , but the
> warning is coming:
It is obviously intentional but also obviously pointless. You might as
well just echo 'Array'; I don't think I have ever encountered a case
where you actually want to convert an array to a string and use the
result in a useful way.
Cheers
--
Jordi Boggiano
@seldaek - http://nelm.io/jordi