This seems weird, when constant values are enabled for case when checking (example):
cmd = CMD.from_value 5
instead of
cmd = CMD.from_value CMD_INDEX_VALUES.shuffle[0]
the Benchmark will report:
case_when_enum 446.48M ( 2.24ns) (± 2.90%) 0.0B/op fastest
case_when_string 440.04M ( 2.27ns) (± 4.04%) 0.0B/op 1.01× slower