Skip to content

Commit 2a678da

Browse files
author
Rastusik
committed
Merge branch '8.1_fixes'
2 parents 039beb2 + 7bfa697 commit 2a678da

File tree

3 files changed

+5
-6
lines changed

3 files changed

+5
-6
lines changed

README.md

+3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
!!! IMPORTANT !!! - THIS IS JUST A FORK OF THE UNMAINTAINED ORIGINAL PACKAGE FOR SPECIAL CASE USAGE WITH THE SWOOLE BUNDLE. NOTHING ELSE IS SUPPORTED !!!
2+
-----------------
3+
14
Z-Engine library
25
-----------------
36

phpunit.xml.dist

+1
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
1212
xsi:noNamespaceSchemaLocation="./vendor/phpunit/phpunit/phpunit.xsd"
1313
colors="true"
14+
convertDeprecationsToExceptions="true"
1415
bootstrap="./tests/bootstrap.php">
1516
<coverage>
1617
<include>

src/Reflection/ReflectionClass.php

+1-6
Original file line numberDiff line numberDiff line change
@@ -884,12 +884,7 @@ public function setInterfaceGetsImplementedHandler(Closure $handler): void
884884
*/
885885
public static function newInstanceRaw(CData $classType, bool $persistent = false): CData
886886
{
887-
$objectSize = Core::sizeof(Core::type('zend_object'));
888-
$totalSize = $objectSize + self::getObjectPropertiesSize($classType);
889-
$memory = Core::new("char[{$totalSize}]", false, $persistent);
890-
$object = Core::cast('zend_object *', $memory);
891-
892-
Core::call('zend_object_std_init', $object, $classType);
887+
$object = Core::call('zend_objects_new', $classType);
893888
$object->handlers = self::getObjectHandlers($classType);
894889
Core::call('object_properties_init', $object, $classType);
895890

0 commit comments

Comments
 (0)