Lightweight dynamic language for the JVM

Golo is a simple dynamic, weakly-typed language for the JVM.

Built from day 1 with invokedynamic, Golo takes advantage of the latest advances of the JVM. It is also a showcase on how to build a language runtime with invokedynamic.

Golo is being developed as part of the research activities of the DynaMid group of the CITI Laboratory at INSA-Lyon.

module samples.Fibonacci

import java.lang.System

function fib = |n| {
  if n <= 1 {
    return n
  } else {
    return fib(n - 1) + fib(n - 2)
  }
}

local function run = {
  let start = System.currentTimeMillis()
  let result = fib(40)
  let duration = System.currentTimeMillis() - start
  println(">>> " + result + " (took " + duration + "ms)")
}

function main = |args| {
  while true {
    run()
  }
}
Information updated 12/07/13
View Comments