I want to have a function that takes a variable number of functions, but I want them to not be evaluated until I actually used them. I could use the () => type syntax, but I would prefer to use the => type syntax, because it seems to be custom made for delaying evaluation.
When I try something like this:
def functions(fns: => String*) = "OK"
I get the error:
error: ')' expected but identifier found.
def functions(fns: => String*) = "OK"
Interestingly, it works fine when I change it to
def functions(fns: () => String*) = "OK"
What do I have to do to get my first function to work?