Find this useful? Enter your email to receive occasional updates for securing PHP code.

Signing you up...

Thank you for signing up!

PHP Decode

--TEST-- Bug #78697: ReflectionClass::implementsInterface - inaccurate error message with ..

Decoded Output download

--TEST--
Bug #78697: ReflectionClass::implementsInterface - inaccurate error message with traits
--FILE--
<?php
trait T {}

try {
    (new ReflectionClass(new stdClass))->implementsInterface(T::class);
} catch (ReflectionException $e) {
    echo $e->getMessage();
}
?>
--EXPECT--
T is not an interface

Did this file decode correctly?

Original Code

--TEST--
Bug #78697: ReflectionClass::implementsInterface - inaccurate error message with traits
--FILE--
<?php
trait T {}

try {
    (new ReflectionClass(new stdClass))->implementsInterface(T::class);
} catch (ReflectionException $e) {
    echo $e->getMessage();
}
?>
--EXPECT--
T is not an interface

Function Calls

None

Variables

None

Stats

MD5 8993b3b67481281a0216f7e042898f5c
Eval Count 0
Decode Time 71 ms