PageRenderTime 48ms CodeModel.GetById 24ms RepoModel.GetById 1ms app.codeStats 0ms

/hphp/test/slow/ext_file/fwrite.php

http://github.com/facebook/hiphop-php
PHP | 17 lines | 12 code | 5 blank | 0 comment | 0 complexity | c9b0b7030a52a245575b5cb124aa368d 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_fwrite() {
  4. $tempfile = tempnam('/tmp', 'vmextfiletest');
  5. $f = fopen($tempfile, 'w');
  6. fwrite($f, "testing fwrite", 7);
  7. fclose($f);
  8. $f = fopen($tempfile, 'r');
  9. fpassthru($f);
  10. echo "\n";
  11. unlink($tempfile);
  12. }