- var_dump: documentation ( source)
<?php
function horrible_function(&$o) {
$o = (object)array('haha' => 'got you');
}
class innocent_bystander {
function operation() {
horrible_function($this);
var_dump($this);
}
}
$h = new innocent_bystander();
$h->operation();