Turn FFP errors upto 11; report everything
[hiphop-php.git] / hphp / test / slow / hni / exception_dtor_order.php
blobac0ee87811185a74fb73c002fd6aa7fafb96834e
1 <?hh
3 class dtor {
4 public function __construct(private int $i) {}
5 public function __destruct() { echo "dtor: $this->i\n"; }
8 class invoker {
9 public function __invoke($x) { throw new exception(); }
10 public function __destruct() { echo "~invoker\n"; }
13 function foo() {
14 try {
15 array_map(new invoker(), array(new dtor(1), new dtor(2)));
16 } catch (exception $x) {
17 echo "ok\n";
20 foo();
21 echo "done\n";