From 37c9b97bc4a62518dead2cea0ec5c45d2ef7be64 Mon Sep 17 00:00:00 2001 From: whitequark Date: Fri, 3 Mar 2017 03:27:49 +0000 Subject: [PATCH] compiler.types: add missing TTuple.__hash__ implementation. --- artiq/compiler/types.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/artiq/compiler/types.py b/artiq/compiler/types.py index e1781116e..17d7f1049 100644 --- a/artiq/compiler/types.py +++ b/artiq/compiler/types.py @@ -194,6 +194,9 @@ class TTuple(Type): def __ne__(self, other): return not (self == other) + def __hash__(self): + return hash(tuple(self.elts)) + class _TPointer(TMono): def __init__(self): super().__init__("pointer")