reference/array/functions/prev.xml
0a192fcd9cc43c0007de795063b4494974058992
...
...
@@ -9,7 +9,7 @@
9
9
&reftitle.description;
10
10
<methodsynopsis>
11
11
<type>mixed</type><methodname>prev</methodname>
12
-
<methodparam><type>array</type><parameter role="reference">array</parameter></methodparam>
12
+
<methodparam><type class="union"><type>array</type><type>object</type></type><parameter role="reference">array</parameter></methodparam>
13
13
</methodsynopsis>
14
14
<para>
15
15
Rewind the internal array pointer.
...
...
@@ -41,7 +41,26 @@
41
41
the internal array pointer, or &false; if there are no more
42
42
elements.
43
43
</para>
44
+
&return.falseproblem;
45
+
</refsect1>
46
+

47
+
<refsect1 role="changelog">
48
+
&reftitle.changelog;
49
+
<informaltable>
50
+
<tgroup cols="2">
51
+
<thead>
52
+
<row>
53
+
<entry>&Version;</entry>
54
+
<entry>&Description;</entry>
55
+
</row>
56
+
</thead>
57
+
<tbody>
58
+
&standard.changelog.calling-on-objects;
59
+
</tbody>
60
+
</tgroup>
61
+
</informaltable>
44
62
</refsect1>
63
+
45
64
<refsect1 role="examples">
46
65
&reftitle.examples;
47
66
<para>
...
...
@@ -64,13 +83,12 @@ $mode = end($transport); // $mode = 'plane';
64
83
</refsect1>
65
84
<refsect1 role="notes">
66
85
&reftitle.notes;
67
-
&return.falseproblem;
68
86
<note>
69
87
<simpara>
70
-
You won't be able to distinguish the beginning of an array from a
71
-
<type>boolean</type> &false; element. To properly traverse an array
72
-
which may contain &false; elements, see the <function>each</function>
73
-
function.
88
+
The beginning of an array is indistinguishable from a
89
+
<type>bool</type> &false; element. To make the distinction, check that
90
+
the <function>key</function> of the <function>prev</function> element is not
91
+
&null;.
74
92
</simpara>
75
93
</note>
76
94
</refsect1>
...
...
@@ -87,7 +105,6 @@ $mode = end($transport); // $mode = 'plane';
87
105
</para>
88
106
</refsect1>
89
107
</refentry>
90
-

91
108
<!-- Keep this comment at the end of the file
92
109
Local variables:
93
110
mode: sgml
94
111