Nueva selección con enlaces a noticias y materiales. En el número: 4 aceptaron propuestas de RFC para PHP 8, incluidos atributos (anotaciones / decoradores), una porción de herramientas útiles, conferencias y reuniones en línea, videos, podcasts y mucho más.
¡Disfruta leyendo!
Noticias y lanzamientos
PHP Internals
[RFC] Attributes v2 — PHP 8 ( / ) << >>
.
<<ExampleAttribute>>
class Foo
{
<<ExampleAttribute>>
public const FOO = 'foo';
<<ExampleAttribute>>
public $x;
<<ExampleAttribute>>
public function foo(<<ExampleAttribute>> $bar) { }
}
$object = new <<ExampleAttribute>> class () { };
<<ExampleAttribute>>
function f1() { }
$f2 = <<ExampleAttribute>> function () { };
$f3 = <<ExampleAttribute>> fn () => 1;
. Benjamin Eberlei <<Deprecated>>
, trigger_error
:
<<Deprecated>>
function test() {}
<<Deprecated("use test3() instead")>>
function test2() {}
[RFC] Allow trailing comma in parameter list — PHP 8 .
class Uri {
private function __construct(
?string $scheme,
?string $user,
?string $pass,
?string $host,
?int $port,
string $path,
?string $query,
?string $fragment, // <-- !
) {
...
}
}
[RFC] Change Default PDO Error Mode — PDO PDO::ERRMODE_EXCEPTION
SQL .
[RFC] Stricter type checks for arithmetic/bitwise operators — , PHP 8 TypeError
, , .
[RFC] Type casting in array destructuring expressions — .- [RFC] Always available JSON extension — JSON .
- [RFC] Match expression —
match
, :
match ($x) {
0 => {
foo();
bar();
baz();
},
}
, feature-freeze PHP 8 , RFC .

Symfony
Laravel
Yii
Async PHP

/
!
— , , .
.
Telegram- PHP Digest.
← : PHP- № 178