appendices/migration70/new-features.xml
389525942dd551c9b1943d404d76c03ab4a6203b
...
...
@@ -9,7 +9,7 @@
9
9

10
10
<para>
11
11
Scalar
12
-
<link linkend="functions.arguments.type-declaration">type declarations</link>
12
+
<link linkend="language.types.declarations">type declarations</link>
13
13
come in two flavours: coercive (default) and strict. The following types
14
14
for parameters can now be enforced (either coercively or strictly): strings
15
15
(<type>string</type>), integers (<literal>int</literal>), floating-point
...
...
@@ -44,7 +44,7 @@ int(9)
44
44
top of the file. This means that the strictness of typing for scalars is
45
45
configured on a per-file basis. This directive not only affects the type
46
46
declarations of parameters, but also a function's return type (see
47
-
<link linkend="functions.returning-values.type-declaration">return type declarations</link>,
47
+
<link linkend="language.types.declarations">return type declarations</link>,
48
48
built-in PHP functions, and functions from loaded
49
49
extensions.
50
50
</para>
...
...
@@ -52,7 +52,7 @@ int(9)
52
52
<para>
53
53
Full documentation and examples of scalar type declarations can be found in
54
54
the
55
-
<link linkend="functions.arguments.type-declaration">type declaration</link>
55
+
<link linkend="language.types.declarations">type declaration</link>
56
56
reference.
57
57
</para>
58
58
</sect2>
...
...
@@ -62,12 +62,12 @@ int(9)
62
62

63
63
<para>
64
64
PHP 7 adds support for
65
-
<link linkend="functions.returning-values.type-declaration">return type declarations</link>.
65
+
<link linkend="language.types.declarations">return type declarations</link>.
66
66
Similarly to
67
-
<link linkend="functions.arguments.type-declaration">argument type declarations</link>,
67
+
<link linkend="language.types.declarations">argument type declarations</link>,
68
68
return type declarations specify the type of the value that will be
69
69
returned from a function. The same
70
-
<link linkend="functions.arguments.type-declaration.types">types</link>
70
+
<link linkend="language.types.declarations">types</link>
71
71
are available for return type declarations as are available for argument
72
72
type declarations.
73
73
</para>
...
...
@@ -103,7 +103,7 @@ Array
103
103
<para>
104
104
Full documentation and examples of return type declarations can be found in
105
105
the
106
-
<link linkend="functions.returning-values.type-declaration">return type declarations</link>.
106
+
<link linkend="language.types.declarations">return type declarations</link>.
107
107
reference.
108
108
</para>
109
109
</sect2>
...
...
@@ -383,7 +383,7 @@ bool(true)
383
383
<title>Expectations</title>
384
384

385
385
<para>
386
-
<link linkend="function.assert.expectations">Expectations</link> are a
386
+
Expectations are a
387
387
backwards compatible enhancement to the older <function>assert</function>
388
388
function. They allow for zero-cost assertions in production code, and
389
389
provide the ability to throw custom exceptions when the assertion fails.
...
...
@@ -393,7 +393,7 @@ bool(true)
393
393
While the old API continues to be maintained for compatibility,
394
394
<function>assert</function> is now a language construct, allowing the first
395
395
parameter to be an expression rather than just a <type>string</type> to be
396
-
evaluated or a <type>boolean</type> value to be tested.
396
+
evaluated or a <type>bool</type> value to be tested.
397
397
</para>
398
398

399
399
<informalexample>
...
...
@@ -418,9 +418,8 @@ Fatal error: Uncaught CustomError: Some error message
418
418

419
419
<para>
420
420
Full details on this feature, including how to configure it in both
421
-
development and production environments, can be found in the
422
-
<link linkend="function.assert.expectations">expectations section</link>
423
-
of the <function>assert</function> reference.
421
+
development and production environments, can be found on the manual page
422
+
of the <function>assert</function> language construct.
424
423
</para>
425
424
</sect2>
426
425

...
...
@@ -640,7 +639,7 @@ session_start([
640
639
</sect2>
641
640

642
641
<sect2 xml:id="migration70.new-features.csprng-functions">
643
-
<title><link linkend="book.csprng">CSPRNG</link> Functions</title>
642
+
<title>CSPRNG Functions</title>
644
643

645
644
<para>
646
645
Two new functions have been added to generate cryptographically secure
647
646