Skip to content

Instantly share code, notes, and snippets.

@chx
Created July 4, 2019 18:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save chx/316be84ee550d5c805b5dbea989f0026 to your computer and use it in GitHub Desktop.
Save chx/316be84ee550d5c805b5dbea989f0026 to your computer and use it in GitHub Desktop.
<?php
interface foo {
}
interface bar {
function foo(Foo $foo);
}
class broken implements bar {
function foo(bar $x) {}
}
<?php
try {
include 'z.php';
}
catch (Throwable $t) {
echo 'caught!';
}
try {
include 'x.php';
}
catch (Throwable $t) {
echo 'caught!';
}
<?php
Broken!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment