I am trying to run the following future basic code
future { println("ssss")} onSuccess{ case _ => println("succ")}
However, when I run the main method, nothing to the console is printed and the system exits almost instantly. I am using the implicit ExecutionContext. Any hints?
This code:
val f = future(Await.ready(Promise().future, d.timeLeft))
f.onSuccess {
case _ => println("hee")
}
also exits immediately....