The current implementation doesn't really handle some of the (messy, bit-level) paths correctly.
It also doesn't provide an enum-level API.
Possibly needs a bitreader implementation (probably as an external dependency), and could make use of num_enum.