1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334
|
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision$ -->
<sect1 xml:id="migration80.other-changes" xmlns:xlink="http://www.w3.org/1999/xlink">
<title>Other Changes</title>
<sect2 xml:id="migration80.other-changes.sapi">
<title>Changes in SAPI Modules</title>
<sect3 xml:id="migration80.other-changes.sapi.apache2handler">
<title>Apache2Handler</title>
<para>
The PHP module has been renamed from <literal>php7_module</literal> to
<literal>php_module</literal>.
</para>
</sect3>
</sect2>
<sect2 xml:id="migration80.other-changes.functions">
<title>Changed Functions</title>
<sect3 xml:id="migration80.other-changes.functions.reflection">
<title>Reflection</title>
<para>
<methodname>ReflectionClass::getConstants</methodname> and
<methodname>ReflectionClass::getReflectionConstants</methodname> results can be now filtered via
a new parameter <parameter>filter</parameter>. Three new constants were added to be used with it:
</para>
<para>
<simplelist>
<member><constant>ReflectionClassConstant::IS_PUBLIC</constant></member>
<member><constant>ReflectionClassConstant::IS_PROTECTED</constant></member>
<member><constant>ReflectionClassConstant::IS_PRIVATE</constant></member>
</simplelist>
</para>
</sect3>
<sect3 xml:id="migration80.other-changes.functions.standard">
<title>Standard</title>
<para>
The math functions <function>abs</function>, <function>ceil</function>,
<function>floor</function> and <function>round</function> now properly heed
<link linkend="language.types.declarations.strict">the <literal>strict_types</literal> directive</link>.
Previously, they coerced the first argument even in strict type mode.
</para>
</sect3>
<sect3 xml:id="migration80.other-changes.functions.zip">
<title>Zip</title>
<itemizedlist>
<listitem>
<para>
The <methodname>ZipArchive::addGlob</methodname> and
<methodname>ZipArchive::addPattern</methodname> methods accept more values in the
<parameter>options</parameter> array argument:
</para>
<para>
<simplelist>
<member><literal>flags</literal></member>
<member><literal>comp_method</literal></member>
<member><literal>comp_flags</literal></member>
<member><literal>env_method</literal></member>
<member><literal>enc_password</literal></member>
</simplelist>
</para>
</listitem>
<listitem>
<para>
<methodname>ZipArchive::addEmptyDir</methodname>, <methodname>ZipArchive::addFile</methodname>
and <methodname>ZipArchive::addFromString</methodname>
methods have a new <parameter>flags</parameter> argument. This allows managing name encoding
(<constant>ZipArchive::FL_ENC_<replaceable>*</replaceable></constant>) and entry replacement
(<constant>ZipArchive::FL_OVERWRITE</constant>).
</para>
</listitem>
<listitem>
<para>
<methodname>ZipArchive::extractTo</methodname> now restores the file modification time.
</para>
</listitem>
</itemizedlist>
</sect3>
</sect2>
<sect2 xml:id="migration80.other-changes.extensions">
<title>Other Changes to Extensions</title>
<sect3 xml:id="migration80.other-changes.extensions.curl">
<title>CURL</title>
<itemizedlist>
<listitem>
<para>
The CURL extension now requires at least libcurl 7.29.0.
</para>
</listitem>
<listitem>
<para>
The deprecated parameter <parameter>version</parameter> of <function>curl_version</function> has
been removed.
</para>
</listitem>
</itemizedlist>
</sect3>
<sect3 xml:id="migration80.other-changes.extensions.date">
<title>Date and Time</title>
<para>
<classname>DatePeriod</classname> now implements <interfacename>IteratorAggregate</interfacename>
(instead of <interfacename>Traversable</interfacename>).
</para>
</sect3>
<sect3 xml:id="migration80.other-changes.extensions.dom">
<title>DOM</title>
<para>
<classname>DOMNamedNodeMap</classname> and <classname>DOMNodeList</classname> now implement
<interfacename>IteratorAggregate</interfacename> (instead of
<interfacename>Traversable</interfacename>).
</para>
</sect3>
<sect3 xml:id="migration80.other-changes.extensions.intl">
<title>Intl</title>
<para>
<classname>IntlBreakIterator</classname> and <classname>ResourceBundle</classname> now implement
<interfacename>IteratorAggregate</interfacename> (instead of <interfacename>Traversable</interfacename>).
</para>
</sect3>
<sect3 xml:id="migration80.other-changes.extensions.enchant">
<title>Enchant</title>
<para>
The enchant extension now uses libenchant-2 by default when available. libenchant version 1 is
still supported but is deprecated and could be removed in the future.
</para>
</sect3>
<sect3 xml:id="migration80.other-changes.extensions.gd">
<title>GD</title>
<itemizedlist>
<listitem>
<para>
The <parameter>num_points</parameter> parameter of <function>imagepolygon</function>,
<function>imageopenpolygon</function> and <function>imagefilledpolygon</function> is now
optional, i.e. these functions may be called with either 3 or 4 arguments. If the argument is
omitted, it is calculated as <code>count($points)/2</code>.
</para>
</listitem>
<listitem>
<para>
The function <function>imagegetinterpolation</function> to get the current interpolation method
has been added.
</para>
</listitem>
</itemizedlist>
</sect3>
<sect3 xml:id="migration80.other-changes.extensions.json">
<title>JSON</title>
<para>
The JSON extension cannot be disabled anymore and is always an integral part of any PHP build,
similar to the date extension.
</para>
</sect3>
<sect3 xml:id="migration80.other-changes.extensions.mbstring">
<title>MBString</title>
<para>
The Unicode data tables have been updated to version 13.0.0.
</para>
</sect3>
<sect3 xml:id="migration80.other-changes.extensions.pdo">
<title>PDO</title>
<para>
<classname>PDOStatement</classname> now implements
<interfacename>IteratorAggregate</interfacename> (instead of
<interfacename>Traversable</interfacename>).
</para>
</sect3>
<sect3 xml:id="migration80.other-changes.extensions.libxml">
<title>LibXML</title>
<para>
The minimum required libxml version is now 2.9.0. This means that external entity loading is now
guaranteed to be disabled by default, and no extra steps need to be taken to protect against XXE
attacks.
</para>
</sect3>
<sect3 xml:id="migration80.other-changes.extensions.mysqli">
<title>MySQLi / PDO MySQL</title>
<itemizedlist>
<listitem>
<para>
When mysqlnd is not used (which is the default and recommended option), the minimum supported
libmysqlclient version is now 5.5.
</para>
</listitem>
<listitem>
<para>
<classname>mysqli_result</classname> now implements
<interfacename>IteratorAggregate</interfacename> (instead of
<interfacename>Traversable</interfacename>).
</para>
</listitem>
</itemizedlist>
</sect3>
<sect3 xml:id="migration80.other-changes.extensions.pgsql">
<title>PGSQL / PDO PGSQL</title>
<para>
The PGSQL and PDO PGSQL extensions now require at least libpq 9.1.
</para>
</sect3>
<sect3 xml:id="migration80.other-changes.extensions.readline">
<title>Readline</title>
<para>
Calling <function>readline_completion_function</function> before the interactive prompt starts
(e.g. in <link linkend="ini.auto-prepend-file">auto_prepend_file</link>) will now override the
default interactive prompt completion function. Previously,
<function>readline_completion_function</function> only worked when called after starting the
interactive prompt.
</para>
</sect3>
<sect3 xml:id="migration80.other-changes.extensions.simplexml">
<title>SimpleXML</title>
<para>
<classname>SimpleXMLElement</classname> now implements
<interfacename>RecursiveIterator</interfacename> and absorbed the functionality of
<classname>SimpleXMLIterator</classname>. <classname>SimpleXMLIterator</classname> is an empty
extension of <classname>SimpleXMLElement</classname>.
</para>
</sect3>
</sect2>
<sect2 xml:id="migration80.other-changes.ini">
<title>Changes to INI File Handling</title>
<itemizedlist>
<listitem>
<para>
<!--<link linkend="ini.com.dotnet-version">-->com.dotnet_version<!--</link>-->
is a new INI directive to choose the version of the .NET framework to use for
<classname>dotnet</classname> objects.
</para>
</listitem>
<listitem>
<para>
<!--<link linkend="ini.zend.exception-string-param-max-len">-->zend.exception_string_param_max_len<!--</link>-->
is a new INI directive to set the maximum string length in an argument of a stringified
stack strace.
</para>
</listitem>
</itemizedlist>
</sect2>
<sect2 xml:id="migration80.other-changes.ebcdic">
<title>EBCDIC</title>
<para>
EBCDIC targets are no longer supported, though it's unlikely that they were still working in the
first place.
</para>
</sect2>
<sect2 xml:id="migration80.other-changes.performance">
<title>Performance</title>
<itemizedlist>
<listitem>
<para>
A Just-In-Time (JIT) compiler has been added to the opcache extension.
<!-- https://wiki.php.net/rfc/jit -->
</para>
</listitem>
<listitem>
<para>
<function>array_slice</function> on an array without gaps will no longer scan the whole array
to find the start offset. This may significantly reduce the runtime of the function with large
offsets and small lengths.
</para>
</listitem>
<listitem>
<para>
<function>strtolower</function> now uses a SIMD implementation when using the
<literal>"C"</literal> <constant>LC_CTYPE</constant> locale (which is the default).
</para>
</listitem>
</itemizedlist>
</sect2>
</sect1>
<!-- Keep this comment at the end of the file
Local variables:
mode: sgml
sgml-omittag:t
sgml-shorttag:t
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:1
sgml-indent-data:t
indent-tabs-mode:nil
sgml-parent-document:nil
sgml-default-dtd-file:"~/.phpdoc/manual.ced"
sgml-exposed-tags:nil
sgml-local-catalogs:nil
sgml-local-ecat-files:nil
End:
vim600: syn=xml fen fdm=syntax fdl=2 si
vim: et tw=78 syn=sgml
vi: ts=1 sw=1
-->
|