Skip to content

Instantly share code, notes, and snippets.

@jponge
Created January 19, 2016 09:52
Show Gist options
  • Save jponge/830844b5f43879893a47 to your computer and use it in GitHub Desktop.
Save jponge/830844b5f43879893a47 to your computer and use it in GitHub Desktop.
import gololang { GoloTuple = Tuple, ... }
import org.typeunsafe { YoCeylon }
import java.lang { JavaInteger = Integer }
shared void run() {
print(">>> eval-style");
value fun = EvaluationEnvironment().def("|a| -> println(a)");
if (is FunctionReference fun) {
fun.invoke("Yo!");
}
print(">>> direct");
value t = YoCeylon.yo(JavaInteger(100));
assert(is GoloTuple t);
print(t.get(0));
print(t.subTuple(3, 10));
print(t);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment