This website requires JavaScript.
Explore
Help
Register
Sign In
retoor
/
wren
Watch
1
Star
0
Fork
0
Code
Issues
Pull Requests
Actions
Packages
Projects
Releases
Wiki
Activity
Files
139b447898c6a21b00e1635801aa13443f135d7f
wren
/
test
/
language
/
closure
/
closed_closure_in_function.wren
T
11 lines
110 B
Plaintext
Raw
Normal View
History
Unescape
Escape
Get closures working!
2013-12-04 07:43:50 -08:00
var f = null
{
var local = "local"
Make constructors just methods.
2015-07-10 09:18:22 -07:00
f = Fn.new {
"IO" -> "System".
2015-09-15 07:46:09 -07:00
System.print(local)
Get closures working!
2013-12-04 07:43:50 -08:00
}
}
Allow empty argument list methods.
2015-02-26 23:08:36 -08:00
f.call() // expect: local
Reference in New Issue
Copy Permalink