3v4l.org

run code in 300+ PHP versions simultaneously
<?php interface A {} interface BB {} interface B extends B {} interface C extends A {} interface I { public function foo(A&B $arg); } interface J extends I { public function foo(BB $arg); }
Output for 8.2.0 - 8.2.28, 8.3.0 - 8.3.20, 8.4.1 - 8.4.6
Fatal error: Uncaught Error: Interface "B" not found in /in/SSr1f:5 Stack trace: #0 {main} thrown in /in/SSr1f on line 5
Process exited with code 255.

preferences:
45.47 ms | 406 KiB | 5 Q