strict_002.phpt 360 B

123456789101112131415161718192021222324252627
  1. --TEST--
  2. assigning static property as non static
  3. --INI--
  4. error_reporting=8191
  5. --FILE--
  6. <?php
  7. class test {
  8. static $foo = 1;
  9. }
  10. $t = new test;
  11. $t->foo = 5;
  12. $fp = fopen(__FILE__, 'r');
  13. var_dump($t);
  14. echo "Done\n";
  15. ?>
  16. --EXPECTF--
  17. Notice: Accessing static property test::$foo as non static in %s on line %d
  18. object(test)#%d (1) {
  19. ["foo"]=>
  20. int(5)
  21. }
  22. Done