diff options
| author | Hugo Porcher <hugo.r.porcher@gmail.com> | 2019-03-27 20:17:02 -0400 |
|---|---|---|
| committer | Hugo Porcher <hugo.r.porcher@gmail.com> | 2019-03-27 20:17:02 -0400 |
| commit | 10900147bccb1abde0c5f6f418ddaafa7bb1594f (patch) | |
| tree | 8e28ae95d75814e688dcadbb4ee953fa2b9cbc8c /test/expression/simplifications.py | |
| parent | 225f5691e6afbeb99c18d91e3511564a93712e11 (diff) | |
| download | miasm-10900147bccb1abde0c5f6f418ddaafa7bb1594f.tar.gz miasm-10900147bccb1abde0c5f6f418ddaafa7bb1594f.zip | |
Add check to not slice an ExprId
Diffstat (limited to 'test/expression/simplifications.py')
| -rw-r--r-- | test/expression/simplifications.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/test/expression/simplifications.py b/test/expression/simplifications.py index b1e590ec..ab235543 100644 --- a/test/expression/simplifications.py +++ b/test/expression/simplifications.py @@ -193,10 +193,9 @@ to_test = [(ExprInt(1, 32) - ExprInt(1, 32), ExprInt(0, 32)), (ExprOp('<<', ExprOp('>>', a, ExprInt(0x4, 32)), ExprInt(0x4, 32)), ExprOp('&', a, ExprInt(0xFFFFFFF0, 32))), - (ExprCompose(ExprInt(0x1234, 16), ExprId("a", 16)) & ExprInt(0xFF, 32), ExprInt(0x34, 32)), + (ExprCompose(ExprId("a", 8), ExprId("b", 24)) & ExprInt(0xFF, 32), ExprCompose(ExprId("a", 8), ExprInt(0x0, 24))), (ExprCompose(ExprInt(0x12, 8), ExprInt(0x34, 8)) & ExprInt(0xFFFF, 16), ExprInt(0x3412, 16)), - (ExprCompose(ExprInt(0x12, 8), ExprInt(0x3456, 16), ExprInt(0x78, 8)) & ExprInt(0xFFFFFF, 32), ExprInt(0x345612, 32)), - (ExprCompose(ExprInt(0x1234, 16), ExprId("a", 8), ExprInt(0x67, 8)) & ExprInt(0xFFFFFFFF, 32), ExprCompose(ExprInt(0x1234, 16), ExprId("a", 8), ExprInt(0x67, 8))), + (ExprCompose(ExprInt(0x12, 8), ExprInt(0x345678, 24)) & ExprInt(0xFFFFFF, 32), ExprInt(0x567812, 32)), (a[:32], a), (a[:8][:8], a[:8]), |