<?php class A { public $a = 'public'; } $method = function (){ $x =& $this; $x = new stdClass; var_dump($this, $this->a);}; $a = new A; $method = $method->bindTo($a); $method();
You have javascript disabled. You will not be able to edit any code.