Fresh selection with links to news and materials. In the release: PHPUnit 9 and other releases, 3 fresh RFC offers from PHP Internals, a portion of useful tools, videos, podcasts and much more.
Enjoy reading!
 News and Releases
 News and Releases
 PHP Internals
 PHP Internals
- [RFC] Allow function calls in constant expressions β , . RFC ( ) , , .        class MyClass {
        const VALUES = [1, 0];
        const C1 = count(self::VALUES);
        public static $p = count(self::VALUES);
        public function foo($param = count(self::VALUES))
        {
        static $bar = count(self::VALUES);
        }
        }
        
 
- [RFC] __toArray() β __toArray(), , array return type array.        class Person
        {
        protected $name;
        protected $email;
        public function __toArray()
        {
        return [
        'name' => $this->name,
        'email'  => $this->email,
        ];
        }
        }
        $person = new Person('John Doe', 'j.doe@example.com');
        $personArray = (array) $person; 
        function foo(array $person) {
        var_dump($person); 
        }
        function bar(Person $person): array {
        return $person;
        }
        var_dump(bar($person)); 
        
 
- [RFC] Userspace operator overloading β PHP. , Internals. PHP 7.4 lisachenko/z-engine.
- [RFC] Validation for abstract trait methods β . :        trait T {
        abstract public function test(int $x);
        }
        class C {
        use T;
        
        public function test(string $x) {}
        }
        
 
 .
 -, , RFC-: , .
- : Static return type, Variable Syntax Tweaks, Allow ::class on objects, declare(function_and_const_lookup='global')
- PHP β PHP.
- php/doc-en β PHP - GitHub edit.php.net.

 Symfony
 Symfony
 Laravel
 Laravel
Async PHP

 /
 /

Thank you for the attention!
If you notice a mistake or inaccuracy - please inform me in PM .
Questions and suggestions write to mail or twitter .
Telegram channel: PHP Digest .
Send link
Search links for all digests
β Previous release: PHP Digest No. 172