def test_remove_identical_variables(): def g(code): pc = 0 while pc < len(code): pc += 1 return pc graph = TranslationContext().buildflowgraph(g) for block in graph.iterblocks(): assert len(block.inputargs) <= 2 # at most 'pc' and 'code'
def test_remove_identical_variables(): def g(code): pc = 0 while pc < len(code): pc += 1 return pc graph = TranslationContext().buildflowgraph(g) for block in graph.iterblocks(): assert len(block.inputargs) <= 2 # at most 'pc' and 'code'