This section assumes that the constant value is a scalar, and so makes no attempts to handle when it is not. Enum classes have object constants, so the InvalidArgumentException is triggered.
Target PHP version: 8.2 (inferred from current PHP version).
Scanning files...
Uncaught InvalidArgumentException: $value must be a scalar. in /data/poe_packages/trunk/development/1/webserver/Website/application/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/ConstantTypeResolver.php:409
Stack trace:
#0 /data/poe_packages/trunk/development/1/webserver/Website/application/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/Reflection.php(169): Psalm\Internal\Codebase\ConstantTypeResolver::getLiteralTypeFromScalarValue(Object(Grindb\Account\Language))
#1 /data/poe_packages/trunk/development/1/webserver/Website/application/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/Scanner.php(486): Psalm\Internal\Codebase\Reflection->registerClass(Object(ReflectionClass))
#2 /data/poe_packages/trunk/development/1/webserver/Website/application/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/Scanner.php(284): Psalm\Internal\Codebase\Scanner->convertClassesToFilePaths(Object(Psalm\Internal\Codebase\ClassLikes))
#3 /data/poe_packages/trunk/development/1/webserver/Website/application/vendor/vimeo/psalm/src/Psalm/Codebase.php(505): Psalm\Internal\Codebase\Scanner->scanFiles(Object(Psalm\Internal\Codebase\ClassLikes), 1)
#4 /data/poe_packages/trunk/development/1/webserver/Website/application/vendor/vimeo/psalm/src/Psalm/Config.php(2443): Psalm\Codebase->scanFiles()
#5 /data/poe_packages/trunk/development/1/webserver/Website/application/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/ProjectAnalyzer.php(529): Psalm\Config->visitStubFiles(Object(Psalm\Codebase), Object(Psalm\Progress\DefaultProgress))
#6 /data/poe_packages/trunk/development/1/webserver/Website/application/vendor/vimeo/psalm/src/Psalm/Internal/Cli/Psalm.php(379): Psalm\Internal\Analyzer\ProjectAnalyzer->check('/data/poe_packa...', true)
#7 /data/poe_packages/trunk/development/1/webserver/Website/application/vendor/vimeo/psalm/psalm(9): Psalm\Internal\Cli\Psalm::run(Array)
#8 /data/poe_packages/trunk/development/1/webserver/Website/application/vendor/bin/psalm(119): include('/data/poe_packa...')
#9 {main}
(Psalm 5.26.1@d747f6500b38ac4f7dfc5edbcae6e4b637d7add0 crashed due to an uncaught Throwable)
https://github.com/vimeo/psalm/blob/d747f6500b38ac4f7dfc5edbcae6e4b637d7add0/src/Psalm/Internal/Codebase/Reflection.php#L163-L173
This section assumes that the constant value is a scalar, and so makes no attempts to handle when it is not. Enum classes have object constants, so the InvalidArgumentException is triggered.