Closed CxDevLead closed 2 years ago
The following code:
enum Subdomain: int { case Test = 0; } $subdomain = Subdomain::Test; $reflectionClass = new ReflectionClass(Subdomain::class); var_dump($subdomain, $reflectionClass->isInstantiable(), $reflectionClass->isEnum());
Resulted in this output:
enum(Subdomain::Test) bool(true) bool(true)
But I expected this output instead:
enum(Subdomain::Test) bool(false) bool(true)
PHP 8.1.1
Mac 12.4
Duplicate, my fault.
Description
The following code:
Resulted in this output:
But I expected this output instead:
PHP Version
PHP 8.1.1
Operating System
Mac 12.4