Move falseproblem under the Return section for consistency.

Update Notes on how to check false values vs. out of bounds elements.

-- 
Provided by anonymous 84645 (petcu.stephan@gmail.com)

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@342936 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
Christoph Michael Becker 2017-08-25 13:45:04 +00:00
parent da772b2649
commit 8b7191a5bc

View file

@ -41,6 +41,7 @@
the internal array pointer, or &false; if there are no more
elements.
</para>
&return.falseproblem;
</refsect1>
<refsect1 role="examples">
&reftitle.examples;
@ -64,13 +65,12 @@ $mode = end($transport); // $mode = 'plane';
</refsect1>
<refsect1 role="notes">
&reftitle.notes;
&return.falseproblem;
<note>
<simpara>
You won't be able to distinguish the beginning of an array from a
<type>boolean</type> &false; element. To properly traverse an array
which may contain &false; elements, see the <function>each</function>
function.
The beginning of an array is indistinguishable from a
<type>boolean</type> &false; element. To make the distinction, check that
the <function>key</function> of the <function>prev</function> element is
strictly different from <type>null</type>.
</simpara>
</note>
</refsect1>