Merge branch 'list-forall' of git://github.com/gsmaverick/wren into gsmaverick-list-forall

This commit is contained in:
Bob Nystrom
2015-01-15 06:52:43 -08:00
6 changed files with 29 additions and 0 deletions
+7
View File
@@ -14,6 +14,13 @@ class Sequence {
}
return result
}
all(f) {
for (element in this) {
if (!f.call(element)) return false
}
return true
}
}
class List is Sequence {