Page MenuHomePhorge

PHP 8.2: fixes for deprecated use of ${var} in strings
ClosedPublic

Authored by valerio.bozzolan on Mar 26 2023, 14:42.
Tags
None
Referenced Files
F2195519: D25098.1716139893.diff
Sat, May 18, 17:31
F2195071: D25098.1716116011.diff
Sat, May 18, 10:53
Unknown Object (File)
Sun, May 12, 01:47
Unknown Object (File)
Sun, May 12, 01:47
Unknown Object (File)
Sun, May 12, 01:47
Unknown Object (File)
Sun, May 12, 01:46
Unknown Object (File)
Wed, May 8, 14:51
Unknown Object (File)
Wed, May 8, 14:51
Tokens
"Like" token, awarded by valerio.bozzolan.

Details

Summary

Note that PHP 8.2 implemented this deprecation:

Using ${var} in strings is deprecated, use {$var} instead

This change fixes some known cases.

Ref T15196

Test Plan
  • I checked with my big eyes that everything is as it should be

Diff Detail

Repository
rP Phorge
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

avivey subscribed.

I have a feeling both of these can be blamed back to me...

This revision is now accepted and ready to land.Mar 26 2023, 18:49

Thanks @avivey honestly it was interesting and deeply connected to a scary PHP internal travel: if I understand correctly, "id" is considered a constant and expanded as the "id" string for backward compatibility reasons. Then, ${} expands that.