changed try to testing for an empty list for legibility (as suggested by paultag), also added to authors
This commit is contained in:
parent
7b7b953410
commit
4c7b4f70e3
1
AUTHORS
1
AUTHORS
@ -13,3 +13,4 @@
|
|||||||
* rogererens <roger.erens@e-s-c.biz>
|
* rogererens <roger.erens@e-s-c.biz>
|
||||||
* Thomas Ballinger <thomasballinger@gmail.com>
|
* Thomas Ballinger <thomasballinger@gmail.com>
|
||||||
* Morten Linderud <mcfoxax@gmail.com>
|
* Morten Linderud <mcfoxax@gmail.com>
|
||||||
|
* Guillermo Vayá <guivaya@gmail.com>
|
@ -70,12 +70,13 @@ _wrappers = {
|
|||||||
|
|
||||||
def process(tree, module_name):
|
def process(tree, module_name):
|
||||||
if isinstance(tree, HyExpression):
|
if isinstance(tree, HyExpression):
|
||||||
try:
|
if tree == []:
|
||||||
fn = tree[0]
|
# set value to []
|
||||||
except IndexError:
|
|
||||||
ntree = HyList()
|
ntree = HyList()
|
||||||
ntree.replace(tree)
|
ntree.replace(tree)
|
||||||
return ntree
|
return ntree
|
||||||
|
|
||||||
|
fn = tree[0]
|
||||||
if fn in ("quote", "quasiquote"):
|
if fn in ("quote", "quasiquote"):
|
||||||
return tree
|
return tree
|
||||||
ntree = HyExpression(
|
ntree = HyExpression(
|
||||||
|
Loading…
Reference in New Issue
Block a user