- marked as trivial
- edited description
Initialize List with Iterable
Issue #135
wontfix
Add a new constructor for the List node which takes an Iterable as argument:
List.List(Iterable<ASTNode> iterable) {
for (ASTNode node : iterable) {
addChild(node);
}
}
This feature was suggested by Jesper Mattsson.
Comments (7)
-
reporter -
- changed milestone to JastAthon2013
-
-
assigned issue to
-
assigned issue to
-
- changed status to resolved
See commit 1bbda37
-
Updated implementation to take a Collection instead of an Iterable. See commit 8d11f42. This is needed because ASTNodes are Iterables. And we don't want a call
new List(new A())
to add the children of A to the list. We want it to add A to the list.
-
Will remove this new constructor. Better to use addAll. See #139.
-
- changed status to wontfix
Should use addAll instead. See #139.
- Log in to comment