3v4l.org

run code in 300+ PHP versions simultaneously
<?php function reference_hash($object) { return spl_object_hash($object); } function value_hash($object) { return md5(print_r($object, true)); } $point1 = (object) ['x' => 1, 'y' => 2]; $point2 = (object) ['x' => 1, 'y' => 2]; var_dump(reference_hash($point1) === reference_hash($point2)); var_dump(value_hash($point1) === value_hash($point2));
Output for rfc.property-hooks, git.master, git.master_jit
bool(false) bool(true)

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
82.29 ms | 2313 KiB | 4 Q