com php-src: Syncronize with 5.6 - __toString should re turn "": ext/spl/spl_iterators.c ext/spl/tests/ spl_cachingiterator___toString_basic.phpt

From: Date: Thu, 13 Oct 2016 07:29:46 +0000
Subject: com php-src: Syncronize with 5.6 - __toString should re turn "": ext/spl/spl_iterators.c ext/spl/tests/ spl_cachingiterator___toString_basic.phpt
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-95008@lists.php.net to get a copy of this message
Commit: 7d014f4bd0e48378d3f5bd1f21e0cb37c93612de Author: Stanislav Malyshev <stas@php.net> Wed, 12 Oct 2016 23:08:30 -0700 Committer: Anatol Belski <ab@php.net> Thu, 13 Oct 2016 09:29:46 +0200 Parents: cb6f00c0a5f380abda201d9d13a10c02ebf97145 Branches: PHP-7.0.12 Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=7d014f4bd0e48378d3f5bd1f21e0cb37c93612de Log: Syncronize with 5.6 - __toString should return "" (cherry picked from commit 2301608736c82183f8210053a45f78eeef5b0c74) Changed paths: M ext/spl/spl_iterators.c M ext/spl/tests/spl_cachingiterator___toString_basic.phpt Diff: diff --git a/ext/spl/spl_iterators.c b/ext/spl/spl_iterators.c index 7b4c73d..6708689 100644 --- a/ext/spl/spl_iterators.c +++ b/ext/spl/spl_iterators.c @@ -2810,7 +2810,7 @@ SPL_METHOD(CachingIterator, __toString) if (Z_TYPE(intern->u.caching.zstr) == IS_STRING) { RETURN_STR_COPY(Z_STR_P(&intern->u.caching.zstr)); } else { - RETURN_NULL(); + RETURN_EMPTY_STRING(); } } /* }}} */ diff --git a/ext/spl/tests/spl_cachingiterator___toString_basic.phpt b/ext/spl/tests/spl_cachingiterator___toString_basic.phpt index 0395b37..57ca515 100644 --- a/ext/spl/tests/spl_cachingiterator___toString_basic.phpt +++ b/ext/spl/tests/spl_cachingiterator___toString_basic.phpt @@ -13,4 +13,4 @@ $ci->__toString() // if conversion to string is done by echo, for example, an ex ); ?> --EXPECTF-- -NULL +string(0) ""

« previous php.cvs (#95008) next »