enum UpDown { up(true), down(false); bool bit; private *(bool *bit) {} static UpDown fromBool(bool bit) { ret bit ? up : down; } }