[presentations] master: More 2023 talks
[email protected] (Derick Rethans) Wed, 12 Jul 2023 11:21:03 +0000
| Newsgroups | php.pres |
|---|---|
| Message-ID | <[email protected]> |
Author: Derick Rethans (derickr) Date: 2023-07-12T12:07:36+01:00 Commit: https://github.com/php/presentations/commit/c6e3dd10a8d8b0a26f938ce0c427665ebe5e8a8b Raw diff: https://github.com/php/presentations/commit/c6e3dd10a8d8b0a26f938ce0c427665ebe5e8a8b.diff More 2023 talks Changed paths: A php-phpsussex23.xml A slides/internals/php83-dynamic-class-constant-fetch.xml A slides/internals/php83-marking-overridden-methods.xml A slides/internals/php83-readonly.xml A slides/internals/php83-typed-class-constants.xml A xdebug-io23.xml A xdebug-planethoster23.xml M slides/internals/php81-fcc.xml M slides/mongodb/me.xml M slides/xdebug/business-support.xml M slides/xdebug/transparency.xml M xdebug-tek23.xml Diff: diff --git a/php-phpsussex23.xml b/php-phpsussex23.xml new file mode 100644 index 00000000..87a3af21 --- /dev/null +++ b/php-phpsussex23.xml @@ -0,0 +1,116 @@ +<?xml version="1.0" encoding="utf-8"?> +<presentation css="derick.css"> +<topic>PHP</topic> +<title>What's New in PHP 8.[123]?</title> +<event>PHP Sussex</event> +<location>Brighton, UK</location> +<date>July 12th, 2023</date> +<speaker>Derick Rethans</speaker> +<email>[email protected]</email> +<twitter>derickr</twitter> +<mastodon>@[email protected]</mastodon> +<url>https://derickrethans.nl/talks/php-phpsussex23</url> +<joindin></joindin> +<slide>slides/xdebug/title.xml</slide> +<slide>slides/mongodb/me.xml</slide> + +<slide>slides/internals/php80-union-types.xml</slide> +<slide>slides/internals/php80-union-types-phpdoc.xml</slide> +<slide>slides/internals/php80-union-types-new.xml</slide> +<slide>slides/internals/php80-union-types-examples.xml</slide> +<slide>slides/internals/php80-union-types-law.xml</slide> +<!--<s lide>slides/internals/php80-union-types-coercive.xml</slide> --> + +Readonly properties 2.0 (https://wiki.php.net/rfc/readonly_properties_v2) +<slide>slides/internals/php81-readonly.xml</slide> + +https://wiki.php.net/rfc/readonly_classes +<slide>slides/internals/php82-readonly.xml</slide> + +https://wiki.php.net/rfc/readonly_amendments +<slide>slides/internals/php83-readonly.xml</slide> + + +Mixed Type v2 +<!-- <s lide>slides/internals/php80-mixed-types.xml</slide> --> + +PHP 8.0: +https://wiki.php.net/rfc/static_return_type +static return type +<!-- <s lide>slides/internals/php80-static-return.xml</slide> --> + +Constructor Property Promotion +<slide>slides/internals/php80-cpp-without.xml</slide> +<slide>slides/internals/php80-cpp-with.xml</slide> + +<slide>slides/internals/php80-named-without.xml</slide> +<slide>slides/internals/php80-named-with.xml</slide> + +<!-- BIG NEW FEATURES --> +Enumerations (https://wiki.php.net/rfc/enumerations) +<slide>slides/internals/php81-enums-1.xml</slide> +<slide>slides/internals/php81-enums-2.xml</slide> +<slide>slides/internals/php81-enums-3.xml</slide> +<slide>slides/internals/php81-enums-4.xml</slide> +<slide>slides/internals/php81-enums-5.xml</slide> +<slide>slides/internals/php81-enums-6.xml</slide> +<slide>slides/internals/php81-enums-7.xml</slide> + +https://wiki.php.net/rfc/fetch_property_in_const_expressions +<slide>slides/internals/php82-enums-1.xml</slide> + +Noreturn type (https://wiki.php.net/rfc/noreturn_type) (never) +<slide>slides/internals/php81-never-type.xml</slide> + +Pure Intersection Types (https://wiki.php.net/rfc/pure-intersection-types) +<slide>slides/internals/php81-pure-intersection.xml</slide> + +Array unpacking with string keys (https://wiki.php.net/rfc/array_unpacking_string_keys) +<slide>slides/internals/php81-array-unpacking.xml</slide> + +Fibers (https://wiki.php.net/rfc/fibers) +<!-- <s lide>slides/internals/php81-fibers.xml</slide> --> + +First Class Callable (https://wiki.php.net/rfc/first_class_callable_syntax) +<slide>slides/internals/php81-fcc.xml</slide> + +PHP 8.2: + +https://wiki.php.net/rfc/null-false-standalone-types +'null' and 'false' as standalone +<slide>slides/internals/php82-null-false-standalone.xml</slide> + +https://wiki.php.net/rfc/true-type +'true' type +<slide>slides/internals/php82-true.xml</slide> + +https://wiki.php.net/rfc/dnf_types +? Disjunctive Normal Form Types +<slide>slides/internals/php82-dnf-types.xml</slide> + +https://wiki.php.net/rfc/rng_extension +<slide>slides/internals/php82-random.xml</slide> + +https://wiki.php.net/rfc/deprecate_dynamic_properties +<slide>slides/internals/php82-deprecate-dynamic-properties.xml</slide> + +https://wiki.php.net/rfc/redact_parameters_in_back_traces +<slide>slides/internals/php82-redact-parameters.xml</slide> + +PHP 8.3: + +https://wiki.php.net/rfc/marking_overriden_methods +<slide>slides/internals/php83-marking-overridden-methods.xml</slide> + +https://wiki.php.net/rfc/typed_class_constants +<slide>slides/internals/php83-typed-class-constants.xml</slide> + +https://wiki.php.net/rfc/dynamic_class_constant_fetch +<slide>slides/internals/php83-dynamic-class-constant-fetch.xml</slide> + +https://wiki.php.net/rfc/arbitrary_static_variable_initializers + +<slide>slides/internals/questions-new.xml</slide> +<slide>slides/xdebug/resources.xml</slide> + +</presentation> diff --git a/slides/internals/php81-fcc.xml b/slides/internals/php81-fcc.xml index 3fd73e87..cd80cb0c 100644 --- a/slides/internals/php81-fcc.xml +++ b/slides/internals/php81-fcc.xml @@ -52,7 +52,7 @@ class Test { public function getPrivateMethod() { |bbbbbb|return [$this, 'privateMethod'];*| |bbbbbb|return Closure::fromCallable([$this, 'privateMethod']);| - *return $this->privateMethod(...);* + *return $this->privateMethod(...);* // new in PHP 8.1 } private function privateMethod() { diff --git a/slides/internals/php83-dynamic-class-constant-fetch.xml b/slides/internals/php83-dynamic-class-constant-fetch.xml new file mode 100644 index 00000000..c6722a8d --- /dev/null +++ b/slides/internals/php83-dynamic-class-constant-fetch.xml @@ -0,0 +1,45 @@ +<slide> +<title>Dynamic Class Constant Fetch</title> + +<blurb>Looking up members' names:</blurb> +<div effect="fade-out"> +<list> + <bullet>Variables: %$$foo%</bullet> + <bullet>Properties: %$foo->$bar%</bullet> + <bullet>Static properties: %Foo::${$bar}%</bullet> + <bullet>Methods: %$foo->{$bar}()%</bullet> + <bullet>Static methods: %Foo::{$bar}()%</bullet> + <bullet>Classes for static properties: %$foo::$bar%</bullet> + <bullet>Classes for static methods: %$foo::bar()%</bullet> + <bullet>---Class constants: %$foo::{$bar}%---</bullet> +</list> +</div> + +<div effect="fade-in"> +<list> + <bullet>…</bullet> + <bullet>Class constants: %$foo::{$bar}%</bullet> +</list> + +<example result="0"><![CDATA[ +<?php +class Foo { + const BAR = 'bar'; +} +$bar = 'BAR'; + +echo Foo::{$bar}; // bar +?>]]></example> + +<blurb>Also works for magic %class% constant:</blurb> +<example result="0"><![CDATA[ +<?php +namespace Foo; +class Bar {} + +$class = 'class'; +echo Bar::{$class}; // Foo\Bar +?>]]></example> + +</div> +</slide> diff --git a/slides/internals/php83-marking-overridden-methods.xml b/slides/internals/php83-marking-overridden-methods.xml new file mode 100644 index 00000000..23ac920a --- /dev/null +++ b/slides/internals/php83-marking-overridden-methods.xml @@ -0,0 +1,51 @@ +<slide> +<title>PHP 8.3: New #[Override] Attribute</title> + +<div effect="fade-out"> +<example><![CDATA[<?php +final class MyApp\Tests\MyTest extends PHPUnit\Framework\TestCase +{ + protected $logFile; + + protected function setUp(): void + { + $this->logFile = fopen('/tmp/logfile', 'w'); + } + + + protected function taerDown(): void + { + fclose($this->logFile); + unlink('/tmp/logfile'); + } +} +?>]]></example> +</div> + +<div effect="fade-in"> +<example inline="1"><![CDATA[<?php +final class MyApp\Tests\MyTest extends PHPUnit\Framework\TestCase +{ + protected $logFile; + + protected function setUp(): void + { + $this->logFile = fopen('/tmp/logfile', 'w'); + } + + *#[\Override]* + protected function *tearDown()*: void + { + fclose($this->logFile); + unlink('/tmp/logfile'); + } +} +?>]]></example> + +<break lines="2"/> + +<blurb>If this attribute is added to a method, PHP validates that a method with +the same name exists in a parent class or any of the implemented +interfaces.</blurb> +</div> +</slide> diff --git a/slides/internals/php83-readonly.xml b/slides/internals/php83-readonly.xml new file mode 100644 index 00000000..3a80623b --- /dev/null +++ b/slides/internals/php83-readonly.xml @@ -0,0 +1,28 @@ +<slide> +<title>Readonly Amendments</title> + +<blurb>In PHP 8.3:</blurb> +<example inline="1"><![CDATA[<?php +class LogEntry +{ + public function __construct( + public readonly string $title, + public readonly DateTimeImmutable $current, + ) {} + + public function __clone() + { + $this->current = new DateTimeImmutable(); + } +} + +$entry = new LogEntry("PHP Sussex is great", new DateTimeImmutable()); +$newEntry = clone $entry; +?>]]></example> + +<div effect="fade-in"> +<break/> +<blurb>You can now re-assign readonly properties during %clone%</blurb> +</div> + +</slide> diff --git a/slides/internals/php83-typed-class-constants.xml b/slides/internals/php83-typed-class-constants.xml new file mode 100644 index 00000000..647ae34c --- /dev/null +++ b/slides/internals/php83-typed-class-constants.xml @@ -0,0 +1,36 @@ +<slide> +<title>PHP 8.3: Typed Class Constants?</title> + +<div effect="fade-out"> +<example><![CDATA[<?php +interface I { + const TEST = "Test"; +} + +class Foo implements I { + const TEST = []; +} + +class Bar extends Foo { + const TEST = null; +} +?>]]></example> +</div> + +<div effect="fade-in"> +<example inline="1"><![CDATA[<?php +interface I { + const *string* TEST = "Test"; +} + +class Foo implements I { + const TEST = []; +} + +class Bar extends Foo { + const float TEST = M_PI; +} +?>]]></example> +</div> + +</slide> diff --git a/slides/mongodb/me.xml b/slides/mongodb/me.xml index bb6531f2..f865fdd0 100644 --- a/slides/mongodb/me.xml +++ b/slides/mongodb/me.xml @@ -13,6 +13,6 @@ <!-- <bullet>Host of *https://phpinternals.news* podcast</bullet> --> <bullet>I ♥🌍 maps, I ♥🍺 beer, I ♥🥃 whisky</bullet> <bullet>mastodon: :-:mastodon:-:</bullet> - <bullet>|999999|twitter: @:-:twitter:-:|</bullet> + <bullet>|aaaaaa|twitter: @:-:twitter:-:|</bullet> </list> </slide> diff --git a/slides/xdebug/business-support.xml b/slides/xdebug/business-support.xml index cfe07637..091149ee 100644 --- a/slides/xdebug/business-support.xml +++ b/slides/xdebug/business-support.xml @@ -8,8 +8,8 @@ <break/> <blurb class="centre"> -iO — TYPO3 GmbH — Tideways — Xdebug Cloud — Seiden Group — Offers.com<br/> -Private Packagist — VEMA eG — Bubble Shooter — Find My Electric +iO Digital — TYPO3 GmbH — Tideways — Xdebug Cloud — Seiden Group — Offers.com<br/> +Private Packagist — VEMA eG — Bubble Shooter — Find My Electric — b13 — 11com7 </blurb> </slide> diff --git a/slides/xdebug/transparency.xml b/slides/xdebug/transparency.xml index 79b49da2..c259308f 100644 --- a/slides/xdebug/transparency.xml +++ b/slides/xdebug/transparency.xml @@ -1,5 +1,5 @@ <slide> <title>Transparency</title> -<image filename="log-july-2020.png"/> +<image filename="log-march-2023.png"/> </slide> diff --git a/xdebug-io23.xml b/xdebug-io23.xml new file mode 100644 index 00000000..f11c2e7c --- /dev/null +++ b/xdebug-io23.xml @@ -0,0 +1,79 @@ +<?xml version="1.0" encoding="utf-8"?> +<presentation css="derick.css"> +<topic>Debugging</topic> +<title>Debugging Our Way Through PHP</title> +<event>iO webinar</event> +<location>London, United Kingdom</location> +<date>May 25th, 2023</date> +<speaker>Derick Rethans</speaker> +<email>[email protected]</email> +<mastodon>@[email protected]</mastodon> +<twitter>derickr</twitter> +<url></url> +<joindin>https://xdebug.org</joindin> +<slide>slides/xdebug/title.xml</slide> +<slide>slides/mongodb/me.xml</slide> + +Code reorganisation +Modes +- only do what is needed +Reduce Configuration Options +Code Improvements (algorithms, memory, etc) +<!--<s lide>slides/xdebug/code-reorgnisation.xml</slide>--> +<slide>slides/xdebug/modes.xml</slide> +<!--slide>slides/xdebug/config-settings-3.xml</slide> --> +<slide>slides/xdebug/config-settings-3b.xml</slide> +<slide>slides/xdebug/xdebug-3-speedup-1.xml</slide> + +- xdebug_info() (demo, VS Code or PhpStorm) + + - an API through xdebug_info() for mode detection (VS Code or PhpStorm) + 'mode' + 'extension-flags' + +<slide>slides/xdebug/xdebug_info.xml</slide> +<slide>slides/xdebug/xdebug_info-2.xml</slide> + +- xdebug_notify() (demo, VS Code) + +<slide>slides/xdebug/xdebug_notify.xml</slide> + +- file_link_format (demo, PhpStorm) + +<slide>slides/xdebug/xdebug_file_link_format.xml</slide> + + + -> ticket + +<!-- <s lide>slides/xdebug/diagnostic-log.xml</slide> - (Also console output) --> + +Step debugging improvements + +<slide>slides/xdebug/breakpoint_resolving.xml</slide> +- breakpoint resolving (demo, PhpStorm) + +<slide>slides/xdebug/return_value.xml</slide> +- return value debugging (demo, VS Code) + +<slide>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) + +<slide>slides/xdebug/xdebug_connect_to_client.xml</slide> +- xdebug_connect_to_client() (demo, PhpStorm) + +<slide>slides/xdebug/xdebug_pseudo_hosts.xml</slide> +- xdebug://gateway and xdebug://nameserver (explain) + +<slide>slides/xdebug/xdebug-cloud-announcement.xml</slide> + +<!--<sli de>slides/xdebug/donate.xml</slide> --> +<slide>slides/xdebug/business-support.xml</slide> +<slide>slides/xdebug/transparency.xml</slide> + + +<!--<s lide>slides/xdebug/phpinternalsnews.xml</slide> --> +<slide>slides/mongodb/questions.xml</slide> +<slide>slides/xdebug/resources.xml</slide> + +</presentation> diff --git a/xdebug-planethoster23.xml b/xdebug-planethoster23.xml new file mode 100644 index 00000000..f9267ed5 --- /dev/null +++ b/xdebug-planethoster23.xml @@ -0,0 +1,79 @@ +<?xml version="1.0" encoding="utf-8"?> +<presentation css="derick.css"> +<topic>Debugging</topic> +<title>Debugging Our Way Through PHP</title> +<event>PlanetHoster webinar</event> +<location>London, United Kingdom</location> +<date>May 25th, 2023</date> +<speaker>Derick Rethans</speaker> +<email>[email protected]</email> +<mastodon>@[email protected]</mastodon> +<twitter>derickr</twitter> +<url></url> +<joindin>https://xdebug.org</joindin> +<slide>slides/xdebug/title.xml</slide> +<slide>slides/mongodb/me.xml</slide> + +Code reorganisation +Modes +- only do what is needed +Reduce Configuration Options +Code Improvements (algorithms, memory, etc) +<!--<s lide>slides/xdebug/code-reorgnisation.xml</slide>--> +<slide>slides/xdebug/modes.xml</slide> +<!--slide>slides/xdebug/config-settings-3.xml</slide> --> +<slide>slides/xdebug/config-settings-3b.xml</slide> +<slide>slides/xdebug/xdebug-3-speedup-1.xml</slide> + +- xdebug_info() (demo, VS Code or PhpStorm) + + - an API through xdebug_info() for mode detection (VS Code or PhpStorm) + 'mode' + 'extension-flags' + +<slide>slides/xdebug/xdebug_info.xml</slide> +<slide>slides/xdebug/xdebug_info-2.xml</slide> + +- xdebug_notify() (demo, VS Code) + +<slide>slides/xdebug/xdebug_notify.xml</slide> + +- file_link_format (demo, PhpStorm) + +<slide>slides/xdebug/xdebug_file_link_format.xml</slide> + + + -> ticket + +<!-- <s lide>slides/xdebug/diagnostic-log.xml</slide> - (Also console output) --> + +Step debugging improvements + +<slide>slides/xdebug/breakpoint_resolving.xml</slide> +- breakpoint resolving (demo, PhpStorm) + +<slide>slides/xdebug/return_value.xml</slide> +- return value debugging (demo, VS Code) + +<slide>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) + +<slide>slides/xdebug/xdebug_connect_to_client.xml</slide> +- xdebug_connect_to_client() (demo, PhpStorm) + +<slide>slides/xdebug/xdebug_pseudo_hosts.xml</slide> +- xdebug://gateway and xdebug://nameserver (explain) + +<slide>slides/xdebug/xdebug-cloud-announcement.xml</slide> + +<!--<sli de>slides/xdebug/donate.xml</slide> --> +<slide>slides/xdebug/business-support.xml</slide> +<slide>slides/xdebug/transparency.xml</slide> + + +<!--<s lide>slides/xdebug/phpinternalsnews.xml</slide> --> +<slide>slides/mongodb/questions.xml</slide> +<slide>slides/xdebug/resources.xml</slide> + +</presentation> diff --git a/xdebug-tek23.xml b/xdebug-tek23.xml index 88a944ed..495d1f55 100644 --- a/xdebug-tek23.xml +++ b/xdebug-tek23.xml @@ -2,7 +2,7 @@ <presentation css="derick.css"> <topic>Debugging</topic> <title>Debugging Our Way Through PHP</title> -<event>php[tel] 2023</event> +<event>php[tek] 2023</event> <location>Chicago, IL, USA</location> <date>May 18th, 2023</date> <speaker>Derick Rethans</speaker> @@ -45,7 +45,7 @@ Code Improvements (algorithms, memory, etc) -> ticket -<!--<s lide>slides/xdebug/diagnostic-log.xml</slide> (Also console output) --> +<!-- <s lide>slides/xdebug/diagnostic-log.xml</slide> - (Also console output) --> Step debugging improvements