PageRenderTime 77ms CodeModel.GetById 30ms RepoModel.GetById 0ms app.codeStats 0ms

/hphp/test/slow/var_export/footer-bug-1.php

http://github.com/facebook/hiphop-php
PHP | 11 lines | 7 code | 1 blank | 3 comment | 0 complexity | 306ce92507cc1d21b50137df4d027632 MD5 | raw file
Possible License(s): LGPL-2.1, BSD-2-Clause, BSD-3-Clause, MPL-2.0-no-copyleft-exception, MIT, LGPL-2.0, Apache-2.0
  1. <?hh
  2. <<__EntryPoint>>
  3. function main_footer_bug_1() {
  4. $str = var_export(varray[Vector {new stdClass()}], true);
  5. // HHVM has a bug with var_export() where the output sometimes contains
  6. // unnecessary blank lines. We do this substitution here so that this
  7. // test's expected output is not affected by this bug.
  8. $str = strtr($str, darray["\n \n" => "\n"]);
  9. echo $str, "\nDone\n";
  10. }