Skip to content

Conversation

@mumumu
Copy link
Member

@mumumu mumumu commented Oct 7, 2025

Based on PHP 8.5 UPGRADE NOTES and past migration guides.

  • TODO

@mumumu mumumu added this to the PHP 8.5 milestone Oct 7, 2025
@mumumu mumumu assigned mumumu and unassigned mumumu Oct 8, 2025
@mumumu mumumu marked this pull request as ready for review October 12, 2025 12:10
@DanielEScherzer
Copy link
Member

I forgot to add UPGRADING for FILTER_THROW_ON_FAILURE and the 2 new classes that added, so it wasn't in #4886 originally - I just added that, can you include them here too?

@TimWolla
Copy link
Member

php/php-src#20239 might also need to be incorporated

@mumumu
Copy link
Member Author

mumumu commented Oct 20, 2025

I forgot to add UPGRADING for FILTER_THROW_ON_FAILURE and the 2 new classes that added, so it wasn't in #4886 originally

Added in 4f86bb5

php/php-src#20239 might also need to be incorporated

Changed in 3d7f6f5

@TimWolla
Copy link
Member

php/php-src#20278

@mumumu
Copy link
Member Author

mumumu commented Oct 25, 2025

php/php-src#20278

Added in a288458.
However, it is not the UPGRADING file as-is; instead, content based on the RFC wording has been added.

@mumumu mumumu force-pushed the php85-migration-guide branch from 5369184 to 928e2f4 Compare October 25, 2025 11:40
Copy link
Member

@Girgias Girgias left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for starting this! I left a lot of comments that I would like to have addressed. :)

Comment on lines +59 to +62
<simpara>
<link linkend="language.operators.execution">The backtick operator</link>
as an alias for <function>shell_exec</function> has been deprecated.
</simpara>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: indentation seems to be missing for the content of the simpara?

<!-- RFC: https://wiki.php.net/rfc/deprecations_php_8_5#deprecate_constant_redeclaration -->

<simpara>
Constant redeclaration has been deprecated.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Constant redeclaration has been deprecated.
Constant redeclaration has been deprecated.
Note that this already generated a warning and will continue to do so.

<!-- RFC: https://wiki.php.net/rfc/deprecations_php_8_5#deprecate_using_values_null_as_an_array_offset_and_when_calling_array_key_exists -->

<simpara>
Using null as an array offset or when calling <function>array_key_exists</function>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Using null as an array offset or when calling <function>array_key_exists</function>
Using &null; as an array offset or when calling <function>array_key_exists</function>

Comment on lines +202 to +210
<simpara>
The <link linkend="object.wakeup">__wakeup()</link> magic method of
<interfacename>DateTimeInterface</interfacename>,
<classname>DateTime</classname>, <classname>DateTimeImmutable</classname>,
<classname>DateTimeZone</classname>, <classname>DateInterval</classname>,
and <classname>DatePeriod</classname> has been deprecated in favour of
the <link linkend="object.unserialize">__unserialize()</link> magic method.
<!-- RFC: https://wiki.php.net/rfc/deprecations_php_8_5#deprecate_the_sleep_and_wakeup_magic_methods -->
</simpara>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't remember if this wasn't reverted with the soft deprecation RFC, so this would need to be removed.

Comment on lines +247 to +250
The <constant>MHASH_<replaceable>*</replaceable></constant> constants
have been deprecated. These have been overlooked when the mhash*() function
family has been deprecated per
<!-- RFC: https://wiki.php.net/rfc/deprecations_php_8_1#mhash_function_family -->
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This text doesn't make much sense as the RFC which is being linked to is in a comment

Comment on lines +185 to +188
The <link linkend="language.oop5.cloning">clone language construct</link>
is now a function and supports reassigning (readonly) properties during
cloning via the new <property>$withProperties</property> parameter.
<!-- RFC: https://wiki.php.net/rfc/clone_with_v2 -->
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@TimWolla it cannot be disabled via disable_functions right?

<title>EXIF</title>

<simpara>
Added OffsetTime* Exif tags.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Added OffsetTime* Exif tags.
Added support for <literal>OffsetTime*</literal> Exif tags.

when validation fails.
The new flag cannot be combined with
<constant>FILTER_NULL_ON_FAILURE</constant>; trying to do so will result
in a <classname>ValueError</classname> being thrown.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
in a <classname>ValueError</classname> being thrown.
in a <exceptionname>ValueError</exceptionname> being thrown.

<title>XSL</title>

<simpara>
The $namespace argument of <methodname>XSLTProcessor::getParameter</methodname>,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The $namespace argument of <methodname>XSLTProcessor::getParameter</methodname>,
The <parameter>$namespace</parameter> argument of <methodname>XSLTProcessor::getParameter</methodname>,

<methodname>XSLTProcessor::setParameter</methodname> and
<methodname>XSLTProcessor::removeParameter</methodname> now actually works
instead of being treated as empty.
This only works if the $name argument does not use Clark notation and is not a
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
This only works if the $name argument does not use Clark notation and is not a
This only works if the <parameter>$name</parameter> argument does not use Clark notation and is not a

Copy link
Member

@Girgias Girgias left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for starting this! I left a lot of comments that I would like to have addressed. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants