English isn't my first language, please be patient.
From PHP 7.3 Deprecated Features
Namespaced assert()
Declaring a function called assert() inside a namespace is deprecated. The assert() function is subject to special handling by the engine, which may lead to inconsistent behavior when defining a namespaced function with the same name.
I'm working on Drupal 7.72, I was checking the process to migrate to PHP 7.3, when it comes to deprecated features I found that assert()
function is used by Drupal core in several files in the folder \misc\typo3\
. The ones I have identified as potential risks are the following:
- docroot\misc\typo3\drupal-security\PharExtensionInterceptor.php
- docroot\misc\typo3\phar-stream-wrapper\src\Interceptor\ConjunctionInterceptor.php
- docroot\misc\typo3\phar-stream-wrapper\src\Interceptor\PharExtensionInterceptor.php
- docroot\misc\typo3\phar-stream-wrapper\src\Interceptor\PharMetaDataInterceptor.php
- docroot\misc\typo3\phar-stream-wrapper\src\PharStreamWrapper.php
- docroot\misc\typo3\phar-stream-wrapper\src\Assertable.php
- docroot\misc\typo3\phar-stream-wrapper\src\Behavior.php
- docroot\misc\typo3\phar-stream-wrapper\src\Manager.php
I'm really confused about how Drupal is declaring assert functions even though they are deprecated, maybe I'm misreading the Documentation? There's some way to test these files to be sure that everything will be working on PHP 7.3?