Likewise I am having problems with @sprintf
Is this because @sprinf is macro? The shorthand of expanding a printf with
format the contents of an array is desirable. I would have expected the
... operator to take an array of length 2 and turn it into 2 arguments.
julia> X=[1 2]
1x2 Array{Int64,2}:
1 2
julia> @sprintf("%d%d",1,2)
"12"
julia> @sprintf("%d%d",X...)
ERROR: @sprintf: wrong number of arguments
julia> @sprintf("%d%d",(1,2)...)
ERROR: @sprintf: wrong number of arguments
julia> @sprintf("%d",X...)
ERROR: error compiling anonymous: unsupported or misplaced expression
... in function anonymous
in sprint at io.jl:460
in sprint at io.jl:464
julia> macroexpand(quote @sprintf("%d%d",X...) end)
:($(Expr(:error, ErrorException("@sprintf: wrong number of
arguments"))))