Make empty macroexpansions do the right thing
This commit is contained in:
parent
54757b8316
commit
bb2b868aaf
@ -1645,15 +1645,15 @@ class HyASTCompiler(object):
|
||||
|
||||
@builds(HyExpression)
|
||||
def compile_expression(self, expression):
|
||||
if expression == []:
|
||||
return self.compile_list(expression)
|
||||
|
||||
# Perform macro expansions
|
||||
expression = macroexpand(expression, self.module_name)
|
||||
if not isinstance(expression, HyExpression):
|
||||
# Go through compile again if the type changed.
|
||||
return self.compile(expression)
|
||||
|
||||
if expression == []:
|
||||
return self.compile_list(expression)
|
||||
|
||||
fn = expression[0]
|
||||
func = None
|
||||
if isinstance(fn, HyKeyword):
|
||||
|
Loading…
x
Reference in New Issue
Block a user