<?php class X { protected $name = 'I am X.'; public function __toString() { return $this->name; } } class Y { public function write(string $classy) { return $classy; } } $x = new X(); $y = new Y(); var_export($y->write($x));
You have javascript disabled. You will not be able to edit any code.