- var_dump: documentation ( source)
<?php
class Text {
protected $text;
public function __construct(void $text)
{
$this->text = $text;
}
public function hello()
{
return $this->text;
}
}
var_dump((new Text(1))->hello());