3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php class A { public $b; public function __construct() { $this->b = new B(); } } class B { public $a; public function __construct() { $this->A = new A(); } } $a = new A(); echo serialize($a);
Output for 7.2.0
Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 4096 bytes) in /in/dnsGP on line 7
Process exited with code 255.
Output for 7.1.10

Process exited with code 137.
Output for 7.0.0 - 7.1.7
Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 4096 bytes) in /in/dnsGP on line 15
Process exited with code 255.
Output for 5.4.12 - 5.6.28
Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 16777216 bytes) in /in/dnsGP on line 7
Process exited with code 255.
Output for 5.3.22 - 5.3.29
Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 523800 bytes) in /in/dnsGP on line 7
Process exited with code 255.