about summary refs log tree commit diff stats
path: root/miasm2/arch/sh4/arch.py
diff options
context:
space:
mode:
authorserpilliere <serpilliere@users.noreply.github.com>2017-04-21 19:38:48 +0200
committerGitHub <noreply@github.com>2017-04-21 19:38:48 +0200
commit19aaed86a09be0bc1a4a79d2077b74b962e4d8ef (patch)
treeb593d0e967424f3f02eb12c0a192ece4a26321fa /miasm2/arch/sh4/arch.py
parent43f4c43cd521c9637b65fec1628d1618a612d2e1 (diff)
parent18ee3f9f2628c4fd98c46898895fb61021e23e3a (diff)
downloadmiasm-19aaed86a09be0bc1a4a79d2077b74b962e4d8ef.tar.gz
miasm-19aaed86a09be0bc1a4a79d2077b74b962e4d8ef.zip
Merge pull request #535 from commial/fix/match_expr-uses
Remove deprecated use of MatchExpr
Diffstat (limited to 'miasm2/arch/sh4/arch.py')
-rw-r--r--miasm2/arch/sh4/arch.py14
1 files changed, 7 insertions, 7 deletions
diff --git a/miasm2/arch/sh4/arch.py b/miasm2/arch/sh4/arch.py
index 3d0eee00..eeafd5f5 100644
--- a/miasm2/arch/sh4/arch.py
+++ b/miasm2/arch/sh4/arch.py
@@ -196,7 +196,7 @@ class sh4_dgpregpinc(m_arg):
         if not isinstance(e, ExprMem):
             return False
         e = e.arg
-        res = MatchExpr(e, ExprOp(self.op, jra), [jra])
+        res = match_expr(e, ExprOp(self.op, jra), [jra])
         if not res:
             return False
         r = res[jra]
@@ -234,7 +234,7 @@ class sh4_dgpreg_imm(sh4_dgpreg):
             v = gpregs.expr.index(e.arg)
             p.disp.value = 0
         elif isinstance(e.arg, ExprOp):
-            res = MatchExpr(e, ExprMem(jra + jrb, self.sz), [jra, jrb])
+            res = match_expr(e, ExprMem(jra + jrb, self.sz), [jra, jrb])
             if not res:
                 return False
             if not isinstance(res[jra], ExprId):
@@ -291,7 +291,7 @@ class sh4_dpc16imm(sh4_dgpreg):
         return v
 
     def encode(self):
-        res = MatchExpr(self.expr, ExprMem(PC + jra, 16), [jra])
+        res = match_expr(self.expr, ExprMem(PC + jra, 16), [jra])
         if not res:
             return False
         if not isinstance(res[jra], ExprInt):
@@ -317,7 +317,7 @@ class sh4_dgbrimm8(sh4_dgpreg):
         if e == ExprMem(GBR):
             self.value = 0
             return True
-        res = MatchExpr(self.expr, ExprMem(GBR + jra, s), [jra])
+        res = match_expr(self.expr, ExprMem(GBR + jra, s), [jra])
         if not res:
             return False
         if not isinstance(res[jra], ExprInt):
@@ -341,7 +341,7 @@ class sh4_dpc32imm(sh4_dpc16imm):
         return v
 
     def encode(self):
-        res = MatchExpr(
+        res = match_expr(
             self.expr, ExprMem((PC & ExprInt(0xFFFFFFFC, 32)) + jra, 32), [jra])
         if not res:
             return False
@@ -362,7 +362,7 @@ class sh4_pc32imm(m_arg):
         return True
 
     def encode(self):
-        res = MatchExpr(self.expr, (PC & ExprInt(0xfffffffc, 32)) + jra, [jra])
+        res = match_expr(self.expr, (PC & ExprInt(0xfffffffc, 32)) + jra, [jra])
         if not res:
             return False
         if not isinstance(res[jra], ExprInt):
@@ -551,7 +551,7 @@ class bs_dr0gp(sh4_dgpreg):
         return True
 
     def encode(self):
-        res = MatchExpr(self.expr, ExprMem(R0 + jra, self.sz), [jra])
+        res = match_expr(self.expr, ExprMem(R0 + jra, self.sz), [jra])
         if not res:
             return False
         r = res[jra]