diff options
| author | serpilliere <devnull@localhost> | 2012-09-17 14:22:02 +0200 |
|---|---|---|
| committer | serpilliere <devnull@localhost> | 2012-09-17 14:22:02 +0200 |
| commit | 79a3bab95183164594e185946e6f241196510fec (patch) | |
| tree | 20c71b36be6bb638eb5e7169a083bed839ac9a70 /miasm/expression/expression.py | |
| parent | ae66cd9178f210bd6d5e198e8fc20698d0feb924 (diff) | |
| download | focaccia-miasm-79a3bab95183164594e185946e6f241196510fec.tar.gz focaccia-miasm-79a3bab95183164594e185946e6f241196510fec.zip | |
expression: fix slice contains
Diffstat (limited to 'miasm/expression/expression.py')
| -rw-r--r-- | miasm/expression/expression.py | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/miasm/expression/expression.py b/miasm/expression/expression.py index 605487f0..f5983e6f 100644 --- a/miasm/expression/expression.py +++ b/miasm/expression/expression.py @@ -559,10 +559,7 @@ class ExprSlice(Expr): def __contains__(self, e): if self == e: return True - for a in self.args: - if a.__contains__(e): - return True - return False + return self.arg.__contains__(e) def __eq__(self, a): if not isinstance(a, ExprSlice): return False @@ -777,3 +774,5 @@ def ExprInt64(i): def ExprInt_from(e, i): return ExprInt(tab_uintsize[e.get_size()](i)) + + |