<?
class Dummy{}
class Test extends ArrayObject{
public function append(Dummy $value){
parent::append($value);
}
}
$d = new Dummy();
$t = new Test();
$t->append($d);
//$t->append('a'); // throws error as expected
PD8KY2xhc3MgRHVtbXl7fQpjbGFzcyBUZXN0IGV4dGVuZHMgQXJyYXlPYmplY3R7CiAgICAgICAgcHVibGljIGZ1bmN0aW9uIGFwcGVuZChEdW1teSAkdmFsdWUpewogICAgICAgICAgICAgICAgcGFyZW50OjphcHBlbmQoJHZhbHVlKTsKICAgICAgICB9Cn0KCiRkID0gbmV3IER1bW15KCk7CiR0ID0gbmV3IFRlc3QoKTsKJHQtPmFwcGVuZCgkZCk7CnZhcl9kdW1wKCR0KTsKLy8kdC0+YXBwZW5kKCdhJyk7IC8vIHRocm93cyBlcnJvciBhcyBleHBlY3RlZAo=