Skip to content

Instantly share code, notes, and snippets.

@kierdavis
Last active August 24, 2016 19:44
Show Gist options
  • Save kierdavis/c6aae40e685d32c8d3c27f5993d5ce3e to your computer and use it in GitHub Desktop.
Save kierdavis/c6aae40e685d32c8d3c27f5993d5ce3e to your computer and use it in GitHub Desktop.
GateKind = enum
gateNot
gateAnd
gateOr
gateNand
gateNor
gateXor
let kind =
case kindStr
of "NOT": gateNot
of "AND": gateAnd
of "OR": gateOr
of "NAND": gateNand
of "NOR": gateNor
of "XOR": gateXor
else:
raise newException(ParseError, "bad kindStr")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment