Get annotations from Expr (#1332)

pull/1337/head
Nikhil Parasaram 5 years ago committed by GitHub
parent 4d2b331ac0
commit 83ef2c6024
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 3
      mythril/laser/smt/expression.py

@ -54,6 +54,9 @@ class Expression(Generic[T]):
def __hash__(self) -> int:
return self.raw.__hash__()
def get_annotations(self, annotation: Any):
return list(filter(lambda x: isinstance(x, annotation), self.annotations))
G = TypeVar("G", bound=Expression)

Loading…
Cancel
Save