Skip to Content
Scalus Club is now open! Join us to get an early access to new features 🎉

Functions

Functions are the same as in Scala 3.

Scalus supports both recursive and non-recursive functions.

compile { val nonRecursiveLambda = (a: BigInt) => a + 1 def recursive(a: BigInt): BigInt = if a == BigInt(0) then 0 else recursive(a - 1) }
Last updated on