facebook / facebook/hhvm

xml_parse encoding difference from php 5.5

Open
#4,837 2 comments 0 reactions 0 assignees View on GitHub
php5 incompatibility
Dominant language
C++
Stars
18.7k
Forks
3.1k
Avg merge
1h 47m
Merged PRs (30d)
2

Description

I noticed a difference in how hhvm's xml_parse handles xml that defines its own encoding. I'm on a slightly old version of hhvm, but didn't see this reported/closed anywhere.

Running

``` php
' );
echo "\n";
```

Produces:
vagrant@mediawiki-vagrant:/vagrant/mediawiki/maintenance$ hhvm --version
HipHop VM 3.3.1 (rel)
Compiler: heads/master-0-g3efe530cd55a886d88b29acc014dde14c4cff755
Repo schema: b538518f4338eecd9dc2ff13865fd306926fde1b
Extension API: 20140829
vagrant@mediawiki-vagrant:/vagrant/mediawiki/maintenance$ hhvm testutf8.php
dÜST
vagrant@mediawiki-vagrant:/vagrant/mediawiki/maintenance$ php5 --version
PHP 5.5.9-1ubuntu4.5 (cli) (built: Oct 29 2014 11:59:10)
Copyright (c) 1997-2014 The PHP Group
Zend Engine v2.5.0, Copyright (c) 1998-2014 Zend Technologies
with Zend OPcache v7.0.3, Copyright (c) 1999-2014, by Zend Technologies
with Xdebug v2.2.3, Copyright (c) 2002-2013, by Derick Rethans
vagrant@mediawiki-vagrant:/vagrant/mediawiki/maintenance$ php5 testutf8.php
dÜST

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.