Exemplo n.º 1
0
 def testcatch2(self):
   eq_(eval(catch(1, throw(1, 2), 3)), 2)
Exemplo n.º 2
0
def make_catch(tag, body):
    if len(tag) != 1: raise DinpySyntaxError()
    return special.catch(preparse(tag[0]), *preparse(body))
Exemplo n.º 3
0
 def testcatch1(self):
   eq_(eval(catch(1, 2)), 2)
Exemplo n.º 4
0
def make_catch(tag, body):
  if len(tag)!=1:  raise DinpySyntaxError()
  return special.catch(preparse(tag[0]), *preparse(body))