Merge branch 'master' of git://github.com/bjorn/wren into bjorn-master

This commit is contained in:
Bob Nystrom
2015-03-03 07:23:47 -08:00
7 changed files with 42 additions and 4 deletions
+10
View File
@@ -0,0 +1,10 @@
var a = [1, 2, 3]
var b = a.any {|x| x > 3 }
IO.print(b) // expect: false
var d = a.any {|x| x > 1 }
IO.print(d) // expect: true
var e = [].any {|x| true }
IO.print(e) // expect: false
+1
View File
@@ -0,0 +1 @@
IO.print([1, 2, 3].any {|x| "truthy" }) // expect: true
+1
View File
@@ -0,0 +1 @@
[1, 2, 3].any("string") // expect runtime error: String does not implement 'call(_)'.