Closed johngarvin-quantinuum closed 1 year ago
For data types that are plain enums, like Opcode, IntPredicate, FloatPredicate, and Linkage, it would be convenient if they were hashable so that they could be used as keys in a dict. For example:
from pyqir import Opcode, IntPredicate dict1 = { Opcode.ADD: "+", Opcode.SUB: "-", } dict2 = { IntPredicate.EQ: "==", IntPredicate.NE: "!=", }
For data types that are plain enums, like Opcode, IntPredicate, FloatPredicate, and Linkage, it would be convenient if they were hashable so that they could be used as keys in a dict. For example: