about summary refs log tree commit diff stats
path: root/test/analysis/depgraph.py
diff options
context:
space:
mode:
authorFabrice Desclaux <fabrice.desclaux@cea.fr>2017-02-15 16:22:21 +0100
committerFabrice Desclaux <fabrice.desclaux@cea.fr>2017-03-13 14:13:14 +0100
commitd0727aa74bf264580e82f37abc9833b75804daca (patch)
treee5ec4298599a5907b45d009c4da2755c6ba523c0 /test/analysis/depgraph.py
parente1fc2de7e4d8662d5b97ceb7d7a9b9ba24acddaa (diff)
downloadmiasm-d0727aa74bf264580e82f37abc9833b75804daca.tar.gz
miasm-d0727aa74bf264580e82f37abc9833b75804daca.zip
Asmbloc: rename asm_label to AsmLabel
Diffstat (limited to 'test/analysis/depgraph.py')
-rw-r--r--test/analysis/depgraph.py24
1 files changed, 12 insertions, 12 deletions
diff --git a/test/analysis/depgraph.py b/test/analysis/depgraph.py
index 429f7dc8..f84f19cc 100644
--- a/test/analysis/depgraph.py
+++ b/test/analysis/depgraph.py
@@ -1,7 +1,7 @@
 """Regression test module for DependencyGraph"""
 from miasm2.expression.expression import ExprId, ExprInt32, ExprAff, ExprCond, \
     ExprInt
-from miasm2.core.asmbloc import asm_label
+from miasm2.core.asmbloc import AsmLabel
 from miasm2.ir.analysis import ira
 from miasm2.ir.ir import IRBlock, AssignBlock
 from miasm2.core.graph import DiGraph
@@ -42,13 +42,13 @@ CST33 = ExprInt32(0x33)
 CST35 = ExprInt32(0x35)
 CST37 = ExprInt32(0x37)
 
-LBL0 = asm_label("lbl0")
-LBL1 = asm_label("lbl1")
-LBL2 = asm_label("lbl2")
-LBL3 = asm_label("lbl3")
-LBL4 = asm_label("lbl4")
-LBL5 = asm_label("lbl5")
-LBL6 = asm_label("lbl6")
+LBL0 = AsmLabel("lbl0")
+LBL1 = AsmLabel("lbl1")
+LBL2 = AsmLabel("lbl2")
+LBL3 = AsmLabel("lbl3")
+LBL4 = AsmLabel("lbl4")
+LBL5 = AsmLabel("lbl5")
+LBL6 = AsmLabel("lbl6")
 
 def gen_irblock(label, exprs_list):
     """ Returns an IRBlock with empty lines.
@@ -114,7 +114,7 @@ def bloc2graph(irgraph, label=False, lines=True):
     # Generate basic blocks
     out_blocks = []
     for label in irgraph.graph.nodes():
-        if isinstance(label, asm_label):
+        if isinstance(label, AsmLabel):
             label_name = label.name
         else:
             label_name = str(label)
@@ -123,7 +123,7 @@ def bloc2graph(irgraph, label=False, lines=True):
             irblock = irgraph.blocks[label]
         else:
             irblock = None
-        if isinstance(label, asm_label):
+        if isinstance(label, AsmLabel):
             out_block = '%s [\n' % label.name
         else:
             out_block = '%s [\n' % label
@@ -154,11 +154,11 @@ def bloc2graph(irgraph, label=False, lines=True):
     out += out_blocks
     # Generate links
     for src, dst in irgraph.graph.edges():
-            if isinstance(src, asm_label):
+            if isinstance(src, AsmLabel):
                 src_name = src.name
             else:
                 src_name = str(src)
-            if isinstance(dst, asm_label):
+            if isinstance(dst, AsmLabel):
                 dst_name = dst.name
             else:
                 dst_name = str(dst)