<?php
$dom = Dom\HTMLDocument::createFromString(<<<HTML
<svg width="1" xmlns:xlink='http://www.w3.org/1999/xlink'>
HTML);
foreach (['svg', 'use', 'mo'] as $tag) {
$el = $dom->getElementsByTagName($tag)[0];
foreach ($el->attributes as $attribute) {
}
}
$rm = new ReflectionMethod($attribute, "__construct");
try {
var_dump($rm->invoke($attribute, 0, 1, 2));
} catch (ReflectionException $exception) {
}
/php-src/ext/dom/node.c:2554: void zim_Dom_Node___construct(zend_execute_data *, zval *): Assertion `0' failed.
Aborted (core dumped)