tree/actor_common: refactor, fix `actorf` for enum types
tree/actor_common: refactor, fix `actorf` for enum types

Use `std::optional` to lazy construct resulting expected value.

uentity/blue-sky-re,uentity/blue-sky-re,uentity/blue-sky-re