createProxy( new Foo(), [ 'doFoo' => function () : void { echo "pre-foo!\n"; }, ], [ 'doFoo' => function () : void { echo "post-foo!\n"; }, ] ); $proxy->doFoo(); })();