Simplify compile
Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
parent
c241236bf5
commit
a9a67e9418
@ -135,8 +135,8 @@ class HyASTCompiler(object):
|
|||||||
|
|
||||||
def compile(self, tree):
|
def compile(self, tree):
|
||||||
try:
|
try:
|
||||||
for _type in _compile_table:
|
_type = type(tree)
|
||||||
if type(tree) == _type:
|
if _type in _compile_table:
|
||||||
return _compile_table[_type](self, tree)
|
return _compile_table[_type](self, tree)
|
||||||
except HyCompileError:
|
except HyCompileError:
|
||||||
# compile calls compile, so we're going to have multiple raise
|
# compile calls compile, so we're going to have multiple raise
|
||||||
|
Loading…
Reference in New Issue
Block a user