Get rid of the special "call" primitive result type.

Instead, Fn.call(...) is a special *method* type that has the same
special sauce. The goal is eventually to get rid of the primitive
result type entirely.
This commit is contained in:
Bob Nystrom
2015-10-03 19:04:11 -07:00
parent e41d9eac7c
commit 812bc15380
4 changed files with 94 additions and 87 deletions
@@ -1,2 +1,2 @@
var f2 = Fn.new {|a, b| System.print(a, b) }
var f2 = Fn.new {|a, b| System.print(a + b) }
f2.call("a") // expect runtime error: Function expects more arguments.