I\'m tearing my hair out trying to figure out how to do the following:
def foo(msf: String, o: Any, os: Any*) = {
println( String.format(msf, o :: List(os
def foo(msf: String, o: AnyRef, os: AnyRef*) =
println( String.format(msf, o :: os.toList : _* ) )
or
def foo(msf: String, o: AnyRef, os: AnyRef*) =
println( msf format (o :: os.toList : _* ) )
I much prefer the latter, though it has no locale* support.
def foo(msf: String, o: AnyRef, os: AnyRef*) =
println( String.format(msf, (o :: os.toList).toArray : _* ))