Skip to content

Instantly share code, notes, and snippets.

Created Jun 13, 2019
What would you like to do?
package metaobjectTest
Annotation 'eval' is an expression that returns the value
returned by the attached DLS that is in interpreted Cyan
object Eval
func run {
var Int sum = @eval("cyan.lang", "Int"){*
var Int count = 0;
for n in 1..10 {
count = count + n
return count;
assert sum == 55;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment