Skip to content

Commit d39fee0

Browse files
committed
Update appendices/sockets
1 parent 42ef2c7 commit d39fee0

File tree

5 files changed

+92
-36
lines changed

5 files changed

+92
-36
lines changed

appendices/migration70/incompatible/other.xml

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<!-- $Revision$ -->
3-
<!-- EN-Revision: 6d2f72b0f2d7fbda2e3aa79ab58f190b4cdac867 Maintainer: yuanyuqiang Status: ready -->
4-
<!-- CREDITS: Luffy -->
3+
<!-- EN-Revision: 6a52dd81e3f791065b4b65a68d393012a7fdd858 Maintainer: yuanyuqiang Status: ready -->
4+
<!-- CREDITS: Luffy, mowangjuanzi -->
55
<sect2 xml:id="migration70.incompatible.other">
66
<title>其他向后兼容相关的变更</title>
77

@@ -352,6 +352,14 @@ foo(1);?>
352352
</para>
353353
</sect3>
354354

355+
<sect3 xml:id="migration70.incompatible.other.break-continue-constant">
356+
<title>常量禁止作为 break 和 continue 的参数</title>
357+
<para>
358+
<literal>break</literal> 和 <literal>continue</literal> 语句不再允许他们的参数为常量,并会触发
359+
<constant>E_COMPILE_ERROR</constant>。
360+
</para>
361+
</sect3>
362+
355363
<sect3 xml:id="migration70.incompatible.other.mhash">
356364
<title>Mhash 不再是一个单独的扩展了</title>
357365
<para>

appendices/migration84/new-features.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ class Example
221221
</simpara>
222222

223223
<simpara>
224-
Status page has a new field to display a memory peak.
224+
状态页面新增字段用于展示内存峰值。
225225
</simpara>
226226
</sect2>
227227

@@ -473,7 +473,7 @@ class Example
473473
</sect2>
474474

475475
<sect2 xml:id="migration84.new-features.standard">
476-
<title>Standard</title>
476+
<title>标准</title>
477477

478478
<!-- RFC: https://wiki.php.net/rfc/correctly_name_the_rounding_mode_and_make_it_an_enum -->
479479
<simpara>

appendices/reserved.constants.core.xml

Lines changed: 14 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: 592b824dd743c3ffd5dce2eefa63628c8e64117e Maintainer: avenger Status: ready -->
3+
<!-- EN-Revision: 499c8c5964ac2d43e305266255cfdbb552492488 Maintainer: avenger Status: ready -->
44
<!-- CREDITS: Luffy, mowangjuanzi -->
55
<sect2 xml:id="reserved.constants.core" xmlns="http://docbook.org/ns/docbook">
66
<title>内核预定义常量</title>
@@ -350,7 +350,19 @@
350350
在 Windows 上,它是配置(configure)时设置的 <option role="configure">--with-prefix</option> 值。
351351
</simpara>
352352
</listitem>
353-
</varlistentry>
353+
</varlistentry>
354+
<varlistentry xml:id="constant.php-sbindir">
355+
<term>
356+
<constant>PHP_SBINDIR</constant>
357+
(<type>string</type>)
358+
</term>
359+
<listitem>
360+
<simpara>
361+
在配置时设置 <option role="configure">--sbindir</option> 的值。在 Windows 上,配置时设置
362+
<option role="configure">--with-prefix</option> 的值。自 PHP 8.4.0 起可用。
363+
</simpara>
364+
</listitem>
365+
</varlistentry>
354366
<varlistentry xml:id="constant.php-binary">
355367
<term>
356368
<constant>PHP_BINARY</constant>

language-snippets.ent

Lines changed: 46 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: 27aaf9a626b5711866a2e6957f568e3c31143760 Maintainer: Gregory Status: ready -->
3+
<!-- EN-Revision: 6b53a028fb43eb697c961c81053543fc51bc9028 Maintainer: Gregory Status: ready -->
44
<!-- CREDITS: dallas, mowangjuanzi, Luffy -->
55
<!-- 请保持此文件与英文文件中相应的每个 ENTITY 行号一一对应以便于对照,修改与更新! -->
66

@@ -1059,6 +1059,7 @@ purposes.</simpara></warning>'>
10591059
</entry>
10601060
</row>'>
10611061

1062+
10621063
<!-- CSV -->
10631064
<!ENTITY warning.csv.escape-parameter '<warning xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink"><simpara>
10641065
当 <parameter>escape</parameter> 被设置为非空字符串(<literal>""</literal>)时,
@@ -1068,6 +1069,7 @@ purposes.</simpara></warning>'>
10681069
默认值将在未来的 PHP 版本中更改,不早于 PHP 9.0。
10691070
</simpara></warning>'>
10701071

1072+
10711073
<!-- DBM notes -->
10721074

10731075
<!ENTITY dbm.dbm-identifier.description '<varlistentry xmlns="http://docbook.org/ns/docbook"><term>
@@ -1476,6 +1478,49 @@ linkend="memcached.expiration" xmlns="http://docbook.org/ns/docbook">到期时
14761478

14771479
<!ENTITY gearman.parameter.jobhandle '由 Gearman 服务器指派的工作句柄。'>
14781480

1481+
<!ENTITY gearman.parameter.callback '<varlistentry xmlns="http://docbook.org/ns/docbook">
1482+
<term><parameter>callback</parameter></term>
1483+
<listitem>
1484+
<para>
1485+
调用的函数或方法。应该返回有效的 <link linkend="gearman.constants">Gearman 返回值</link>。
1486+
</para>
1487+
<para>
1488+
如果没有返回语句,默认是 <constant>GEARMAN_SUCCESS</constant>。
1489+
</para>
1490+
<methodsynopsis>
1491+
<type>int</type><methodname><replaceable>callback</replaceable></methodname>
1492+
<methodparam><type>GearmanTask</type><parameter>task</parameter></methodparam>
1493+
<methodparam><type>mixed</type><parameter>context</parameter></methodparam>
1494+
</methodsynopsis>
1495+
<variablelist>
1496+
<varlistentry>
1497+
<term><parameter>task</parameter></term>
1498+
<listitem>
1499+
<para>
1500+
调用此 callback 的任务。
1501+
</para>
1502+
</listitem>
1503+
</varlistentry>
1504+
<varlistentry>
1505+
<term><parameter>context</parameter></term>
1506+
<listitem>
1507+
<para>
1508+
Whatever has been passed to <methodname>GearmanClient::addTask</methodname> (or equivalent method) as <parameter>context</parameter>.
1509+
</para>
1510+
</listitem>
1511+
</varlistentry>
1512+
</variablelist>
1513+
</listitem>
1514+
</varlistentry>'>
1515+
1516+
<!ENTITY gearman.note.callback '<note xmlns="http://docbook.org/ns/docbook">
1517+
<para>
1518+
The callback will only be triggered for tasks that are added (e.g. by calling <methodname>GearmanClient::addTask</methodname>)
1519+
after calling this method.
1520+
</para>
1521+
</note>'>
1522+
1523+
14791524
<!-- Date and time entities -->
14801525
<!ENTITY date.timezone.intro.title '<title xmlns="http://docbook.org/ns/docbook">所支持的时区列表</title>'>
14811526

reference/sockets/functions/socket-create.xml

Lines changed: 20 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -182,33 +182,25 @@
182182

183183
<refsect1 role="changelog">
184184
&reftitle.changelog;
185-
<para>
186-
<informaltable>
187-
<tgroup cols="2">
188-
<thead>
189-
<row>
190-
<entry>&Version;</entry>
191-
<entry>&Description;</entry>
192-
</row>
193-
</thead>
194-
<tbody>
195-
<row>
196-
<entry>5.0.0</entry>
197-
<entry>
198-
增加 <constant>AF_INET6</constant> 支持。
199-
</entry>
200-
</row>
201-
<row>
202-
<entry>8.0.0</entry>
203-
<entry>
204-
创建成功时,该函数现在返回一个 <classname>Socket</classname> 实例;
205-
在此之前,返回的是一个 <type>resource</type>。
206-
</entry>
207-
</row>
208-
</tbody>
209-
</tgroup>
210-
</informaltable>
211-
</para>
185+
<informaltable>
186+
<tgroup cols="2">
187+
<thead>
188+
<row>
189+
<entry>&Version;</entry>
190+
<entry>&Description;</entry>
191+
</row>
192+
</thead>
193+
<tbody>
194+
<row>
195+
<entry>8.0.0</entry>
196+
<entry>
197+
创建成功时,该函数现在返回一个 <classname>Socket</classname> 实例;
198+
在此之前,返回的是一个 <type>resource</type>。
199+
</entry>
200+
</row>
201+
</tbody>
202+
</tgroup>
203+
</informaltable>
212204
</refsect1>
213205

214206
<refsect1 role="seealso">
@@ -224,9 +216,8 @@
224216
</simplelist>
225217
</para>
226218
</refsect1>
227-
228-
</refentry>
229219

220+
</refentry>
230221
<!-- Keep this comment at the end of the file
231222
Local variables:
232223
mode: sgml

0 commit comments

Comments
 (0)