- var_dump: documentation ( source)
<?php
trait foo {
static $bar = [];
public static function a() {
static::$bar = ["foo"];
echo "Goodbye Moon";
}
}
class bing {
use foo;
static $bar = [];
public static function a() {
foo::a();
var_dump(static::$bar, foo::$bar);
}
}
bing::a();