### Symfony version(s) affected 7.0.0 ### Description Dumper for enums return !php/const instead of !php/enum ### How to reproduce ``` $dump = Yaml::dump(Level::Debug, 256); var_dump($dump); ``` gives: ``` "!php/const Monolog\Level::Debug" ``` ### Possible Solution The yaml component properly evolves php/const in such situations and returns an enum anyway, but this is confusing. Replace in Inline.php this line ``` case $value instanceof \UnitEnum: return sprintf('!php/const %s::%s', $value::class, $value->name); ``` and corresponding tests ### Additional Context _No response_