Skip to content

Commit a1b7749

Browse files
[PHP 8.4] Document some SPL changes in PHP-8.4 (#233)
* spl系の翻訳 * 空行を原文とあわせる対応 --------- Co-authored-by: 武田 憲太郎 <[email protected]>
1 parent 02a3af4 commit a1b7749

File tree

7 files changed

+193
-31
lines changed

7 files changed

+193
-31
lines changed

reference/spl/splfixedarray/setsize.xml

Lines changed: 35 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<!-- $Revision$ -->
3-
<!-- EN-Revision: d51166ca16fda8e766849505b84f9306ef443f71 Maintainer: takagi Status: ready -->
3+
<!-- EN-Revision: 03674dde72012054d8e7d34d97ce9f10aef24bd5 Maintainer: takagi Status: ready -->
44
<refentry xml:id="splfixedarray.setsize" xmlns="http://docbook.org/ns/docbook">
55
<refnamediv>
66
<refname>SplFixedArray::setSize</refname>
@@ -10,7 +10,7 @@
1010
<refsect1 role="description">
1111
&reftitle.description;
1212
<methodsynopsis role="SplFixedArray">
13-
<modifier>public</modifier> <type>bool</type><methodname>SplFixedArray::setSize</methodname>
13+
<modifier>public</modifier> <type>true</type><methodname>SplFixedArray::setSize</methodname>
1414
<methodparam><type>int</type><parameter>size</parameter></methodparam>
1515
</methodsynopsis>
1616
<para>
@@ -41,21 +41,41 @@
4141

4242
<refsect1 role="returnvalues">
4343
&reftitle.returnvalues;
44-
<para>
45-
&return.success;
46-
</para>
44+
<simpara>
45+
&return.true.always;
46+
</simpara>
4747
</refsect1>
48-
49-
50-
<refsect1 role="errors"><!-- {{{ -->
48+
49+
<refsect1 role="errors">
5150
&reftitle.errors;
52-
<para>
53-
<parameter>size</parameter> が負の数である場合に <classname>InvalidArgumentException</classname> をスローします。
54-
</para>
55-
<para>
56-
<parameter>size</parameter> を数値として解釈できない場合に <constant>E_WARNING</constant> が発生します。
57-
</para>
58-
</refsect1><!-- }}} -->
51+
<simpara>
52+
<parameter>size</parameter> が0未満の場合、
53+
<exceptionname>ValueError</exceptionname> をスローします。
54+
</simpara>
55+
</refsect1>
56+
57+
<refsect1 role="changelog">
58+
&reftitle.changelog;
59+
<informaltable>
60+
<tgroup cols="2">
61+
<thead>
62+
<row>
63+
<entry>&Version;</entry>
64+
<entry>&Description;</entry>
65+
</row>
66+
</thead>
67+
<tbody>
68+
<row>
69+
<entry>8.4.0</entry>
70+
<entry>
71+
<methodname>SplFixedArray::setSize</methodname> は
72+
現在、暫定的に <type>true</type> を返しています。
73+
</entry>
74+
</row>
75+
</tbody>
76+
</tgroup>
77+
</informaltable>
78+
</refsect1>
5979

6080

6181
<refsect1 role="examples">

reference/spl/splfixedarray/wakeup.xml

Lines changed: 28 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,16 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<!-- $Revision$ -->
3-
<!-- EN-Revision: d51166ca16fda8e766849505b84f9306ef443f71 Maintainer: takagi Status: ready -->
3+
<!-- EN-Revision: 03674dde72012054d8e7d34d97ce9f10aef24bd5 Maintainer: takagi Status: ready -->
44
<refentry xml:id="splfixedarray.wakeup" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
55
<refnamediv>
66
<refname>SplFixedArray::__wakeup</refname>
77
<refpurpose>アンシリアライズ後に配列を再初期化する</refpurpose>
88
</refnamediv>
99

10+
<refsynopsisdiv>
11+
&warn.deprecated.function-8-4-0;
12+
</refsynopsisdiv>
13+
1014
<refsect1 role="description">
1115
&reftitle.description;
1216
<methodsynopsis role="SplFixedArray">
@@ -29,6 +33,29 @@
2933
&return.void;
3034
</para>
3135
</refsect1>
36+
37+
<refsect1 role="changelog">
38+
&reftitle.changelog;
39+
<informaltable>
40+
<tgroup cols="2">
41+
<thead>
42+
<row>
43+
<entry>&Version;</entry>
44+
<entry>&Description;</entry>
45+
</row>
46+
</thead>
47+
<tbody>
48+
<row>
49+
<entry>8.4.0</entry>
50+
<entry>
51+
このメソッドは非推奨となりました。
52+
<methodname>SplFixedArray::__unserialize</methodname> を代わりに使ってください。
53+
</entry>
54+
</row>
55+
</tbody>
56+
</tgroup>
57+
</informaltable>
58+
</refsect1>
3259
</refentry>
3360
<!-- Keep this comment at the end of the file
3461
Local variables:

reference/spl/splheap/insert.xml

Lines changed: 25 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<!-- $Revision$ -->
3-
<!-- EN-Revision: f781803449007bb0e3a96c693e0eee067f7eb466 Maintainer: takagi Status: ready -->
3+
<!-- EN-Revision: 03674dde72012054d8e7d34d97ce9f10aef24bd5 Maintainer: takagi Status: ready -->
44
<refentry xml:id="splheap.insert" xmlns="http://docbook.org/ns/docbook">
55
<refnamediv>
66
<refname>SplHeap::insert</refname>
@@ -41,7 +41,30 @@
4141
&return.true.always;
4242
</para>
4343
</refsect1>
44-
44+
45+
<refsect1 role="changelog">
46+
&reftitle.changelog;
47+
<informaltable>
48+
<tgroup cols="2">
49+
<thead>
50+
<row>
51+
<entry>&Version;</entry>
52+
<entry>&Description;</entry>
53+
</row>
54+
</thead>
55+
<tbody>
56+
<row>
57+
<entry>8.4.0</entry>
58+
<entry>
59+
<methodname>SplHeap::insert</methodname> は
60+
現在、暫定的に <type>true</type> を返しています。
61+
</entry>
62+
</row>
63+
</tbody>
64+
</tgroup>
65+
</informaltable>
66+
</refsect1>
67+
4568
</refentry>
4669
<!-- Keep this comment at the end of the file
4770
Local variables:

reference/spl/splheap/recoverfromcorruption.xml

Lines changed: 28 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<!-- $Revision$ -->
3-
<!-- EN-Revision: d51166ca16fda8e766849505b84f9306ef443f71 Maintainer: takagi Status: ready -->
3+
<!-- EN-Revision: 03674dde72012054d8e7d34d97ce9f10aef24bd5 Maintainer: takagi Status: ready -->
44
<refentry xml:id="splheap.recoverfromcorruption" xmlns="http://docbook.org/ns/docbook">
55
<refnamediv>
66
<refname>SplHeap::recoverFromCorruption</refname>
@@ -10,7 +10,7 @@
1010
<refsect1 role="description">
1111
&reftitle.description;
1212
<methodsynopsis role="SplHeap">
13-
<modifier>public</modifier> <type>bool</type><methodname>SplHeap::recoverFromCorruption</methodname>
13+
<modifier>public</modifier> <type>true</type><methodname>SplHeap::recoverFromCorruption</methodname>
1414
<void/>
1515
</methodsynopsis>
1616
</refsect1>
@@ -22,9 +22,32 @@
2222

2323
<refsect1 role="returnvalues">
2424
&reftitle.returnvalues;
25-
<para>
26-
常に &true; を返します。
27-
</para>
25+
<simpara>
26+
&return.true.always;
27+
</simpara>
28+
</refsect1>
29+
30+
<refsect1 role="changelog">
31+
&reftitle.changelog;
32+
<informaltable>
33+
<tgroup cols="2">
34+
<thead>
35+
<row>
36+
<entry>&Version;</entry>
37+
<entry>&Description;</entry>
38+
</row>
39+
</thead>
40+
<tbody>
41+
<row>
42+
<entry>8.4.0</entry>
43+
<entry>
44+
<methodname>SplHeap::recoverFromCorruption</methodname> は
45+
現在、暫定的に <type>true</type> を返しています。
46+
</entry>
47+
</row>
48+
</tbody>
49+
</tgroup>
50+
</informaltable>
2851
</refsect1>
2952

3053
</refentry>

reference/spl/splobjectstorage.xml

Lines changed: 25 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<!-- $Revision$ -->
3-
<!-- EN-Revision: 14767af0f05dffa6fdb9b49e1a1f4e9ca7022a60 Maintainer: takagi Status: ready -->
3+
<!-- EN-Revision: 03674dde72012054d8e7d34d97ce9f10aef24bd5 Maintainer: takagi Status: ready -->
44
<reference xml:id="class.splobjectstorage" role="class" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xi="http://www.w3.org/2001/XInclude">
55

66
<title>SplObjectStorage クラス</title>
@@ -34,7 +34,7 @@
3434
</oointerface>
3535

3636
<oointerface>
37-
<interfacename>Iterator</interfacename>
37+
<interfacename>SeekableIterator</interfacename>
3838
</oointerface>
3939

4040
<oointerface>
@@ -136,6 +136,29 @@ array(3) {
136136
</section>
137137
<!-- }}} -->
138138

139+
<section role="changelog">
140+
&reftitle.changelog;
141+
<informaltable>
142+
<tgroup cols="2">
143+
<thead>
144+
<row>
145+
<entry>&Version;</entry>
146+
<entry>&Description;</entry>
147+
</row>
148+
</thead>
149+
<tbody>
150+
<row>
151+
<entry>8.4.0</entry>
152+
<entry>
153+
以前は <interfacename>Iterator</interfacename> を実装していましたが、
154+
<interfacename>SeekableIterator</interfacename> を実装しました。
155+
</entry>
156+
</row>
157+
</tbody>
158+
</tgroup>
159+
</informaltable>
160+
</section>
161+
139162
</partintro>
140163

141164
&reference.spl.entities.splobjectstorage;

reference/spl/splpriorityqueue/insert.xml

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<!-- $Revision$ -->
3-
<!-- EN-Revision: bad9acb50797346b072f9ff6addf05ee6c385570 Maintainer: takagi Status: ready -->
3+
<!-- EN-Revision: 03674dde72012054d8e7d34d97ce9f10aef24bd5 Maintainer: takagi Status: ready -->
44
<refentry xml:id="splpriorityqueue.insert" xmlns="http://docbook.org/ns/docbook">
55
<refnamediv>
66
<refname>SplPriorityQueue::insert</refname>
@@ -51,6 +51,29 @@
5151
</para>
5252
</refsect1>
5353

54+
<refsect1 role="changelog">
55+
&reftitle.changelog;
56+
<informaltable>
57+
<tgroup cols="2">
58+
<thead>
59+
<row>
60+
<entry>&Version;</entry>
61+
<entry>&Description;</entry>
62+
</row>
63+
</thead>
64+
<tbody>
65+
<row>
66+
<entry>8.4.0</entry>
67+
<entry>
68+
<methodname>SplPriorityQueue::insert</methodname> は
69+
現在、暫定的に <type>true</type> を返しています。
70+
</entry>
71+
</row>
72+
</tbody>
73+
</tgroup>
74+
</informaltable>
75+
</refsect1>
76+
5477
</refentry>
5578
<!-- Keep this comment at the end of the file
5679
Local variables:

reference/spl/splpriorityqueue/recoverfromcorruption.xml

Lines changed: 28 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<!-- $Revision$ -->
3-
<!-- EN-Revision: d51166ca16fda8e766849505b84f9306ef443f71 Maintainer: takagi Status: ready -->
3+
<!-- EN-Revision: 03674dde72012054d8e7d34d97ce9f10aef24bd5 Maintainer: takagi Status: ready -->
44
<refentry xml:id="splpriorityqueue.recoverfromcorruption" xmlns="http://docbook.org/ns/docbook">
55
<refnamediv>
66
<refname>SplPriorityQueue::recoverFromCorruption</refname>
@@ -10,7 +10,7 @@
1010
<refsect1 role="description">
1111
&reftitle.description;
1212
<methodsynopsis role="SplPriorityQueue">
13-
<modifier>public</modifier> <type>bool</type><methodname>SplPriorityQueue::recoverFromCorruption</methodname>
13+
<modifier>public</modifier> <type>true</type><methodname>SplPriorityQueue::recoverFromCorruption</methodname>
1414
<void/>
1515
</methodsynopsis>
1616
</refsect1>
@@ -22,9 +22,32 @@
2222

2323
<refsect1 role="returnvalues">
2424
&reftitle.returnvalues;
25-
<para>
26-
常に &true; を返します。
27-
</para>
25+
<simpara>
26+
&return.true.always;
27+
</simpara>
28+
</refsect1>
29+
30+
<refsect1 role="changelog">
31+
&reftitle.changelog;
32+
<informaltable>
33+
<tgroup cols="2">
34+
<thead>
35+
<row>
36+
<entry>&Version;</entry>
37+
<entry>&Description;</entry>
38+
</row>
39+
</thead>
40+
<tbody>
41+
<row>
42+
<entry>8.4.0</entry>
43+
<entry>
44+
<methodname>SplPriorityQueue::recoverFromCorruption</methodname> は
45+
現在、暫定的に <type>true</type> を返しています。
46+
</entry>
47+
</row>
48+
</tbody>
49+
</tgroup>
50+
</informaltable>
2851
</refsect1>
2952

3053
</refentry>

0 commit comments

Comments
 (0)