3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr = [ (object)['Name' => 'Kory Kelly', 'PhoneNumber' => '(555) 555-5555'], (object)['Name' => 'Kory Kelly', 'PhoneNumber' => '(555) 555-5555'], (object)['Name' => 'Kory Kelly', 'PhoneNumber' => '(555) 555-5555X'], //different ]; foreach($arr as $key => $object){ $arr[json_encode($object)] = $object; unset($arr[$key]); } $arr = array_values($arr); var_dump($arr);
Output for git.master, git.master_jit, rfc.property-hooks
array(2) { [0]=> object(stdClass)#2 (2) { ["Name"]=> string(10) "Kory Kelly" ["PhoneNumber"]=> string(14) "(555) 555-5555" } [1]=> object(stdClass)#3 (2) { ["Name"]=> string(10) "Kory Kelly" ["PhoneNumber"]=> string(15) "(555) 555-5555X" } }

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:
27.14 ms | 406 KiB | 5 Q