changeset 215:98957794e778

secret_analysis: handle tuples
author Sigurd Meldgaard <stm@daimi.au.dk>
date Wed, 23 Dec 2009 14:31:26 +0100
parents c2f5f0ff0501
children 7c32c0b6bc39
files pysmcl/secret_annotator.py
diffstat 1 files changed, 2 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/pysmcl/secret_annotator.py	Wed Dec 23 13:02:01 2009 +0100
+++ b/pysmcl/secret_annotator.py	Wed Dec 23 14:31:26 2009 +0100
@@ -63,6 +63,8 @@
         return expr_secret(exp.value, secret_variables)
     elif isinstance(exp, ast.Subscript):
         return expr_secret(exp.value, secret_variables)
+    elif isinstance(exp, ast.Tuple):
+        return any([expr_secret(i, secret_variables) for i in exp.elts])
     else:
         assert False, "Not implemented of type %s" % type(exp)