handle AST_Seq elements in AST_Seq.from_array()
This commit is contained in:
parent
5088aeedac
commit
3232dd4d89
|
|
@ -610,7 +610,13 @@ var AST_Seq = DEFNODE("Seq", "car cdr", {
|
|||
var i = array.length - 1;
|
||||
var list = array[i];
|
||||
while (--i >= 0) {
|
||||
list = AST_Seq.cons(array[i], list);
|
||||
var node = array[i];
|
||||
if (node instanceof AST_Seq) {
|
||||
node.add(list);
|
||||
list = node;
|
||||
} else {
|
||||
list = AST_Seq.cons(array[i], list);
|
||||
}
|
||||
}
|
||||
return list;
|
||||
},
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user