[PRES] [presentations] master: Add Leeds PHP and Rotterdam PHP talks
[email protected] (Derick Rethans) Mon, 10 Nov 2025 12:14:18 +0000
| Newsgroups | php.pres |
|---|---|
| Message-ID | <[email protected]> |
Author: Derick Rethans (derickr) Date: 2025-11-10T12:12:01Z Commit: https://github.com/php/presentations/commit/4bd6e9d68168a22a99acd49c8bf3d7b5fa354c5d Raw diff: https://github.com/php/presentations/commit/4bd6e9d68168a22a99acd49c8bf3d7b5fa354c5d.diff Add Leeds PHP and Rotterdam PHP talks Changed paths: A php-leeds25.xml A php-rotterdam25.xml A slides/internals/php85-fcc-in-constant-expressions2.xml M slides/internals/php85-closures-in-constant-expressions.xml M slides/internals/php85-fcc-in-constant-expressions.xml M slides/internals/php85-pipes.xml M xdebug-ipc25.xml Diff: diff --git a/php-leeds25.xml b/php-leeds25.xml new file mode 100644 index 00000000..300743b9 --- /dev/null +++ b/php-leeds25.xml @@ -0,0 +1,119 @@ +<?xml version="1.0" encoding="utf-8"?> +<presentation css="derick.css"> +<topic>PHP</topic> +<title>What's New in PHP 8.5</title> +<event>Leeds PHP</event> +<location>Leeds, United Kingdom</location> +<date>November 19th, 2025</date> +<speaker>Derick Rethans</speaker> +<email>[email protected]</email> +<twitter>derickr</twitter> +<mastodon>@[email protected]</mastodon> +<url>https://derickrethans.nl/talks/php-leeds25</url> +<joindin></joindin> +<slide>slides/xdebug/title.xml</slide> +<slide>slides/mongodb/me.xml</slide> + + +Syntax: + +https://wiki.php.net/rfc/closures_in_const_expr +<slide>slides/internals/php85-closures-in-constant-expressions.xml</slide> + +https://wiki.php.net/rfc/fcc_in_const_expr +<slide>slides/internals/php85-fcc-in-constant-expressions.xml</slide> +<slide>slides/internals/php85-fcc-in-constant-expressions2.xml</slide> + +https://wiki.php.net/rfc/pipe-operator-v3 +<slide>slides/internals/php85-pipes.xml</slide> +<!--<s lide>slides/internals/php85-pipes-debug.xml</slide>--> +<!-- +https://wiki.php.net/rfc/asymmetric-visibility-v2 +<slide>slides/internals/php84-asymmetric-visibility.xml</slide> +<slide>slides/internals/php84-asymmetric-visibility-2.xml</slide> + +https://wiki.php.net/rfc/static-aviz +<slide>slides/internals/php85-asymmetric-visibility-static.xml</slide> + +https://wiki.php.net/rfc/final_promotion +<slide>slides/internals/php85-final-property-promotion.xml</slide> +--> + +https://wiki.php.net/rfc/clone_with_v2 +<slide>slides/internals/php85-clone-with.xml</slide> + +Major additions: + +https://wiki.php.net/rfc/url_parsing_api +<slide>slides/internals/php85-url-parsing-api.xml</slide> + +https://wiki.php.net/rfc/make_opcache_required +<slide>slides/internals/php85-opcache-required.xml</slide> + + +Minor additions: + +Attributes: + +<!-- +https://wiki.php.net/rfc/attributes-on-constants +<slide>slides/internals/php85-attributes-on-constants.xml</slide> +--> +https://wiki.php.net/rfc/marking_return_value_as_important +<slide>slides/internals/php85-nodiscard-attribute.xml</slide> + +<!-- +https://wiki.php.net/rfc/deprecated_traits +<slide>slides/internals/php85-deprecated-trait-attribute.xml</slide> +--> + +<!-- +https://wiki.php.net/rfc/delayedtargetvalidation_attribute +<s lide>slides/internals/php85-delayed-target-validation-attribute.xml</slide> +--> + +https://wiki.php.net/rfc/error_backtraces_v2 +<slide>slides/internals/php85-error-backtraces.xml</slide> + +https://wiki.php.net/rfc/filter_throw_on_failure +<slide>slides/internals/php85-filter-throw.xml</slide> + +https://wiki.php.net/rfc/array_first_last +<slide>slides/internals/php85-array-first-last.xml</slide> + + +Language stuff: +https://wiki.php.net/rfc/grapheme_str_split +<slide>slides/internals/php84-grapheme-str-split.xml</slide> +<slide>slides/internals/php84-grapheme-str-split-2.xml</slide> +<slide>slides/internals/php84-grapheme-str-split-3.xml</slide> + +https://wiki.php.net/rfc/grapheme_levenshtein +<slide>slides/internals/php85-grapheme-levenstein.xml</slide> +<slide>slides/internals/php85-grapheme-levenstein2.xml</slide> + +https://wiki.php.net/rfc/grapheme_add_locale_for_case_insensitive +<slide>slides/internals/php85-grapheme-levenstein3.xml</slide> +<slide>slides/internals/php85-grapheme-add-locale.xml</slide> + +Deprecations: + +Deprecations for PHP 8.5 +https://wiki.php.net/rfc/deprecations_php_8_5 + + +Policy: + +Abstain voting option for RFCs +https://wiki.php.net/rfc/rfc_vote_abstain +<slide>slides/internals/policy-vote-abstain.xml</slide> + +Recommend PIE and deprecate PECL +https://wiki.php.net/rfc/adopt_pie_deprecate_pecl +<slide>slides/internals/policy-adopt-pie.xml</slide> + + +<slide>slides/internals/questions-new.xml</slide> +<slide>slides/xdebug/resources.xml</slide> + +</presentation> diff --git a/php-rotterdam25.xml b/php-rotterdam25.xml new file mode 100644 index 00000000..4d99f541 --- /dev/null +++ b/php-rotterdam25.xml @@ -0,0 +1,115 @@ +<?xml version="1.0" encoding="utf-8"?> +<presentation css="derick.css"> +<topic>PHP</topic> +<title>What's New in PHP 8.5</title> +<event>RotterdamPHP</event> +<location>Rotterdam, The Netherlands</location> +<date>November 20th, 2025</date> +<speaker>Derick Rethans</speaker> +<email>[email protected]</email> +<twitter>derickr</twitter> +<mastodon>@[email protected]</mastodon> +<url>https://derickrethans.nl/talks/php-rotterdam25</url> +<joindin></joindin> +<slide>slides/xdebug/title.xml</slide> +<slide>slides/mongodb/me.xml</slide> + + +Syntax: + +https://wiki.php.net/rfc/closures_in_const_expr +<slide>slides/internals/php85-closures-in-constant-expressions.xml</slide> + +https://wiki.php.net/rfc/fcc_in_const_expr +<slide>slides/internals/php85-fcc-in-constant-expressions.xml</slide> +<slide>slides/internals/php85-fcc-in-constant-expressions2.xml</slide> + +https://wiki.php.net/rfc/pipe-operator-v3 +<slide>slides/internals/php85-pipes.xml</slide> +<!--<s lide>slides/internals/php85-pipes-debug.xml</slide>--> + +https://wiki.php.net/rfc/asymmetric-visibility-v2 +<slide>slides/internals/php84-asymmetric-visibility.xml</slide> +<slide>slides/internals/php84-asymmetric-visibility-2.xml</slide> + +https://wiki.php.net/rfc/static-aviz +<slide>slides/internals/php85-asymmetric-visibility-static.xml</slide> + +https://wiki.php.net/rfc/final_promotion +<slide>slides/internals/php85-final-property-promotion.xml</slide> + +https://wiki.php.net/rfc/clone_with_v2 +<slide>slides/internals/php85-clone-with.xml</slide> + +Major additions: + +https://wiki.php.net/rfc/url_parsing_api +<slide>slides/internals/php85-url-parsing-api.xml</slide> + +https://wiki.php.net/rfc/make_opcache_required +<slide>slides/internals/php85-opcache-required.xml</slide> + + +Minor additions: + +Attributes: + +https://wiki.php.net/rfc/attributes-on-constants +<slide>slides/internals/php85-attributes-on-constants.xml</slide> + +https://wiki.php.net/rfc/marking_return_value_as_important +<slide>slides/internals/php85-nodiscard-attribute.xml</slide> + +https://wiki.php.net/rfc/deprecated_traits +<slide>slides/internals/php85-deprecated-trait-attribute.xml</slide> + +<!-- +https://wiki.php.net/rfc/delayedtargetvalidation_attribute +<s lide>slides/internals/php85-delayed-target-validation-attribute.xml</slide> +--> + +https://wiki.php.net/rfc/error_backtraces_v2 +<slide>slides/internals/php85-error-backtraces.xml</slide> + +https://wiki.php.net/rfc/filter_throw_on_failure +<slide>slides/internals/php85-filter-throw.xml</slide> + +https://wiki.php.net/rfc/array_first_last +<slide>slides/internals/php85-array-first-last.xml</slide> + + +Language stuff: +https://wiki.php.net/rfc/grapheme_str_split +<slide>slides/internals/php84-grapheme-str-split.xml</slide> +<slide>slides/internals/php84-grapheme-str-split-2.xml</slide> +<slide>slides/internals/php84-grapheme-str-split-3.xml</slide> + +https://wiki.php.net/rfc/grapheme_levenshtein +<slide>slides/internals/php85-grapheme-levenstein.xml</slide> +<slide>slides/internals/php85-grapheme-levenstein2.xml</slide> + +https://wiki.php.net/rfc/grapheme_add_locale_for_case_insensitive +<slide>slides/internals/php85-grapheme-levenstein3.xml</slide> +<slide>slides/internals/php85-grapheme-add-locale.xml</slide> + +Deprecations: + +Deprecations for PHP 8.5 +https://wiki.php.net/rfc/deprecations_php_8_5 + + +Policy: + +Abstain voting option for RFCs +https://wiki.php.net/rfc/rfc_vote_abstain +<slide>slides/internals/policy-vote-abstain.xml</slide> + +Recommend PIE and deprecate PECL +https://wiki.php.net/rfc/adopt_pie_deprecate_pecl +<slide>slides/internals/policy-adopt-pie.xml</slide> + + +<slide>slides/internals/questions-new.xml</slide> +<slide>slides/xdebug/resources.xml</slide> + +</presentation> diff --git a/slides/internals/php85-closures-in-constant-expressions.xml b/slides/internals/php85-closures-in-constant-expressions.xml index d17b8287..8ec60663 100644 --- a/slides/internals/php85-closures-in-constant-expressions.xml +++ b/slides/internals/php85-closures-in-constant-expressions.xml @@ -2,28 +2,20 @@ <title>PHP 8.5: Closures in Constant Expressions</title> <example><![CDATA[<?php -function slugger( - string $input, - array $callbacks = [ - static function ($value) { return \strtolower($value); }, - static function ($value) { return \preg_replace('/[^a-z]/', '-', $value); }, - static function ($value) { return \trim($value, '-'); }, - static function ($value) { return \preg_replace('/-+/', '-', $value); }, - ] -) { - foreach ($callbacks as $callback) { - $input = $callback($input); - } - return $input; +final class Country +{ + $[\Validator\Custom(static function ($countryCode) { + return \preg_match('/^[a-z]{2,3}$/', $countryCode); + })] + public string $countryCode; } - -var_dump(slugger('Hello, World!')); // string(11) "hello-world" ?>]]></example> <list> <bullet>They must be %static%</bullet> - <bullet>They may not include variables from the surrounding scope<br/>no: -%use($foo)%, nor: short closures (%fn … =>%)</bullet> + <bullet>They may not include variables from the surrounding scope.</bullet> + <bullet>*Forbidden:* %use($foo)%</bullet> + <bullet>*Forbidden:* short closures: %fn() => …%</bullet> </list> </slide> diff --git a/slides/internals/php85-fcc-in-constant-expressions.xml b/slides/internals/php85-fcc-in-constant-expressions.xml index c7e0d661..c392747a 100644 --- a/slides/internals/php85-fcc-in-constant-expressions.xml +++ b/slides/internals/php85-fcc-in-constant-expressions.xml @@ -2,28 +2,20 @@ <title>PHP 8.5: First Class Callables in Constant Expressions</title> <example><![CDATA[<?php -function slugger( - string $input, - array $callbacks = [ - \strtolower(...), - static function ($value) { return \preg_replace('/[^a-z]/', '-', $value); }, - static function ($value) { return \trim($value, '-'); }, - static function ($value) { return \preg_replace('/-+/', '-', $value); }, - ] -) { - foreach ($callbacks as $callback) { - $input = $callback($input); - } - return $input; +final class LogEntry +{ + public string $message; + + #[\Serialize\Custom(self::myMethod(...))] + public string $severity; } - -var_dump(slugger('Hello, World!')); // string(11) "hello-world" ?>]]></example> <div effect="fade-in"> <list> <bullet>They must be free-standing functions or %static% methods</bullet> - <bullet>%__callStatic()% methods,<br/>or % [ClassName::class, 'methodName'](...)% is not supported</bullet> + <bullet>*Forbidden:* %__callStatic()% methods</bullet> + <bullet>*Forbidden:* %[ClassName::class, 'methodName'](...)%</bullet> </list> </div> diff --git a/slides/internals/php85-fcc-in-constant-expressions2.xml b/slides/internals/php85-fcc-in-constant-expressions2.xml new file mode 100644 index 00000000..1dd1865e --- /dev/null +++ b/slides/internals/php85-fcc-in-constant-expressions2.xml @@ -0,0 +1,29 @@ +<slide> +<title>PHP 8.5: First Class Callables in Constant Expressions</title> + +<blurb class="center">Potential use case: PHPUnit data provider</blurb> + +<example inline="2"><![CDATA[<?php +final class MyCleverTest +{ + ---#[DataProvider('dataProvider')]--- + + *#[DataProvider(self::dataProvider(...))]* + public testTheThing($input, $expected) : void + { + $result = $input * $input; + self::assertSame($expected, $result); + } + + private dataProvider() + { + return [ + [ 0, 0 ], + [ 1, 1 ], + [ 2, 4 ], + ] + } +} +?>]]></example> +</slide> + diff --git a/slides/internals/php85-pipes.xml b/slides/internals/php85-pipes.xml index 048dafe1..9a4a25f1 100644 --- a/slides/internals/php85-pipes.xml +++ b/slides/internals/php85-pipes.xml @@ -1,6 +1,43 @@ <slide> <title>PHP 8.5: Pipe Operator</title> +<div effect="fade-out"> +<example><![CDATA[<?php +function slugger(string $input) +{ + return + preg_replace( + '/-+/', '-', + trim( + preg_replace( + /[^a-z]/', '-', + strtolower($input) + ), + '-' + ) + ); +} + +var_dump(slugger('Hello, World!')); // string(11) "hello-world" +?>]]></example> +</div> + +<div effect="fade-in-out"> +<example><![CDATA[<?php +function slugger(string $input) +{ + $input = \strtolower($input); + $input = \preg_replace('/[^a-z]/', '-', $input)); + $input = \trim($input, '-'); + $input = \preg_replace('/-+/', '-', $input)); + return $input; +} + +var_dump(slugger('Hello, World!')); // string(11) "hello-world" +?>]]></example> +</div> + +<div effect="fade-in"> <example><![CDATA[<?php function slugger(string $input) { @@ -10,14 +47,23 @@ function slugger(string $input) |> (fn($x) => \trim($x, '-')) |> (fn($x) => \preg_replace('/-+/', '-', $x)); } +var_dump(slugger('Hello, World!')); // string(11) "hello-world" +?>]]></example> +</div> - - - - - - +<div effect="fade-in"> +<blurb>Maybe in PHP 8.6...</blurb> +<example><![CDATA[<?php +function slugger(string $input) +{ + return $input + |> \strtolower(...) + |> \preg_replace('/[^a-z]/', '-', ?) + |> \trim(?, '-') + |> \preg_replace('/-+/', '-', ?); +} var_dump(slugger('Hello, World!')); // string(11) "hello-world" ?>]]></example> +</div> </slide> diff --git a/xdebug-ipc25.xml b/xdebug-ipc25.xml index 253eeded..8519837c 100644 --- a/xdebug-ipc25.xml +++ b/xdebug-ipc25.xml @@ -35,6 +35,10 @@ Code Improvements (algorithms, memory, etc) <!-- <s lide>slides/xdebug/xdebug_info-2.xml</slide> --> <slide>slides/xdebug/xdebug-native-path-mapping.xml</slide> <slide>slides/xdebug/dbgp-breakpoint-types.xml</slide> + +<slide>slides/xdebug/exception_value.xml</slide> +- exception value as pseudo-variable (VS Code) + <slide>slides/xdebug/xdebug-native-path-skipping.xml</slide> - xdebug_notify() (demo, VS Code) @@ -59,9 +63,6 @@ Step debugging improvements <slide>slides/xdebug/return_value.xml</slide> - return value debugging (demo, VS Code or PhpStorm) -<slide>slides/xdebug/exception_value.xml</slide> -- exception value as pseudo-variable (VS Code) - <!-- <s lide>slides/xdebug/breakpoint_not_resolving.xml</slide> --> - Xdebug will now also log a warning if an IDE attempts to set a breakpoint on a file that does not exist on the file system. (demo, PhpStorm)