summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAsmir Mustafic <[email protected]>2019-03-10 13:02:28 +0100
committerAsmir Mustafic <[email protected]>2019-03-10 13:02:28 +0100
commit707c2ff7b7ccbc1ebfabbde12ef92e2dce47714c (patch)
tree5a96a4d03b60e69f765a0db66b8c6c02d34b37b6 /src
parentc961ca6a0a81dc6b55b6859b3f9ea7f402edf9ad (diff)
drop hhvm support
Diffstat (limited to 'src')
-rw-r--r--src/HTML5/Parser/DOMTreeBuilder.php12
-rw-r--r--src/HTML5/Serializer/OutputRules.php4
2 files changed, 2 insertions, 14 deletions
diff --git a/src/HTML5/Parser/DOMTreeBuilder.php b/src/HTML5/Parser/DOMTreeBuilder.php
index f01cf4d..9894625 100644
--- a/src/HTML5/Parser/DOMTreeBuilder.php
+++ b/src/HTML5/Parser/DOMTreeBuilder.php
@@ -391,11 +391,6 @@ class DOMTreeBuilder implements EventHandler
// to avoid spl_object_hash collisions whe have to avoid garbage collection of $ele storing it into $pushes
// see https://bugs.php.net/bug.php?id=67459
$this->pushes[spl_object_hash($ele)] = array($pushes, $ele);
-
- // SEE https://github.com/facebook/hhvm/issues/2962
- if (defined('HHVM_VERSION')) {
- $ele->setAttribute('html5-php-fake-id-attribute', spl_object_hash($ele));
- }
}
foreach ($attributes as $aName => $aVal) {
@@ -509,12 +504,7 @@ class DOMTreeBuilder implements EventHandler
$lname = Elements::normalizeSvgElement($lname);
}
- // See https://github.com/facebook/hhvm/issues/2962
- if (defined('HHVM_VERSION') && ($cid = $this->current->getAttribute('html5-php-fake-id-attribute'))) {
- $this->current->removeAttribute('html5-php-fake-id-attribute');
- } else {
- $cid = spl_object_hash($this->current);
- }
+ $cid = spl_object_hash($this->current);
// XXX: HTML has no parent. What do we do, though,
// if this element appears in the wrong place?
diff --git a/src/HTML5/Serializer/OutputRules.php b/src/HTML5/Serializer/OutputRules.php
index 41616d5..1c4e892 100644
--- a/src/HTML5/Serializer/OutputRules.php
+++ b/src/HTML5/Serializer/OutputRules.php
@@ -167,9 +167,7 @@ class OutputRules implements RulesInterface
$this->outputMode = static::IM_IN_HTML;
$this->out = $output;
-
- // If HHVM, see https://github.com/facebook/hhvm/issues/2727
- $this->hasHTML5 = defined('ENT_HTML5') && !defined('HHVM_VERSION');
+ $this->hasHTML5 = defined('ENT_HTML5');
}
public function addRule(array $rule)