PHP 8.1 will have an enum, and two more accepted, two rejected and three new RFCs for PHP 8.1. WordPress is used by 40% of sites. Why you need to remove strict_types, why you shouldn't use empty (), as well as tools, videos, articles, podcasts, and PHP Digest Live at 10:00 UTC .
Enjoy reading!
News and releases
- PhpStorm 2021.1 EAP
IDE. , . : -, HTML , .
2020.3.1 / Code With Me. - xdebug.cloud
Xdebug, β PHP- , , Docker, Vagrant, . - WordPress 40% 10 β w3techs .
- 2021- PHP? β 27 .
- 25 , 19:00 PHP of By. Β« - PHPΒ» temporal.io.
- phpcommunity.ru.
PHP Internals
- [RFC] Enumerations
44 7 . PHP 8.1 enum.
enum RfcStatus { case Draft; case UnderDiscussion; case Accepted; } function setRfcStatus(RfcStatus $status) :void { // ... } setRFCStatus(RfcStatus::Accepted); // setRFCStatus('Draft'); // Deprecation notice 8.1, TypeError 9.0
RFC php.watch.
Symfony . - [RFC] Deprecate passing null to non-nullable arguments of internal functions
PHPnull
,nullable
.
PHP 8.1TypeError
. ,str_contains("", null)
. 3v4l.org/OVoa0A.
: , PHP. - [RFC] Array unpacking with string keys
PHP 8.1 , :
$array1 = ['a' => 'apple', 'p' => 'pear']; $array2 = ['b' => 'banana', 'o' => 'orange']; $array = [...$array1, ...$array2]; // : $array = array_merge($array1, $array2);
- [RFC] Fibers
, .
Fiber API Ruby.
ReactPHP trowski/react-fiber:
$loop = new FiberLoop(Factory::create()); $browser = new Browser($loop); $request = function (string $method, string $url) use ($browser, $loop): void { /** @var Response $response */ $response = $loop->await($browser->requestStreaming($method, $url)); /** @var ReadableStreamInterface $stream */ $stream = $response->getBody(); $body = $loop->await(Stream\buffer($stream)); var_dump(\sprintf( '%s %s; Status: %d; Body length: %d', $method, $url, $response->getStatusCode(), \strlen($body) )); }; $requests = []; $requests[] = $loop->async($request, 'GET', 'https://reactphp.org'); $requests[] = $loop->async($request, 'GET', 'https://google.com'); $requests[] = $loop->async($request, 'GET', 'https://www.php.net'); $loop->await(Promise\all($requests));
- [RFC] CachedIterable (rewindable, allows any key&repeating keys)
Tyson Andre . . - Proposal: namespace the SPL
Spl
:Spl\FixedArray
->SplFixedArray
. ,CachedIterable
ReverseIterator
.
azjezz/psl.
- [RFC] mysqli bind in execute
Kamil Tekielamysqli
. RFCmysqli_stmt::execute()
. , ,mysqli_stmt::bind_param()
. , bind_param . - [RFC] PHP\iterable\any() and all() on iterables β
any()
all()
. - [RFC] var_representation(): readable alternative to var_export() β
var_export
, brick/varexporter. - [Draft] Unify PHP's typing modes β PHP . β , , β
strict_types=1
β . , , .
George Peter Banyard, RFC.
. - Observer API PHP 8 β API . Xdebug, APM- New Relic, Tideways, ..
- renoki-co/php-k8s β PHP.
- marcocesarato/php-conventional-changelog β changelog .
- andrey-helldar/package-wizard β CLI- .
- rryqszq4/ngx_php7 β nginx PHP. PHP, /, , .
Symfony
- symfony/panther 1.0 β Symfony Selenium WebDriver E2E .
- Tobias Nyholm: Symfony Lock Messenger
- .
- Symfony #738 (15-21 2021)
Laravel
- middleware Laravel.
- Laravel.
- Laravel Internals #4 β Laravel.
- Laravelβ (8β21 2021)
Yii
Async PHP
- swow/swow β PHP, libuv, , PDO, file_get_ontents() .. ( ). , Swoole.
PhpStorm
- PhpStorm Christoph Rumpel.
- 26 PhpStorm
- Dependency Confusion PHP.
- Benjamin Eberlei: empty() PHP? .
- PHP β .
- MySQL > 40000 QPS, β .
- .
- : , , .
- , - PHP.
- SafetyNet Attestation β PHP.
- Tagged Unions PHP ( Rust).
- : ?
/
- shutdown β () PHP Point.
- PHP ( , Simtech Development)
- . PHP, MySQL, .
- PHP β85 β CTO «», Apache Camel, PHP 4 , Lamoda.
- PHP Release Radar #5 β Flysystem 2 Frank de Jonge.
- PHP Internals News podcast with Nikita Popov about the accepted RFCs for PHP 8.1: deprecate null, and array unpacking , restrict globals usage, and phase out serializable .
Entertaining
- mario-deluna / php-render is a pure PHP 3D renderer, even without using FFI. Shaders, parser .obj files and more. Example
code :
Already a traditional stream based on PHP Digest. There will be a parsing of news and links from the issue with details and additional details.
Beginning at 20:00 Moscow, Minsk / 19:00 Kiev.
If you notice an error or inaccuracy, please let us know in a personal Habr or telegram .
More news and comments on the PHP Digest Telegram channel .
Send link
Search links in all digests
β Previous issue: PHP-Digest β 198