Help with error: "N not defined" in method signature but it is

Okay, these seem to be the droids you’re looking for:

julia> function test(x::Vector{T}, y)::(NTuple{N,T} where N) where T
           return (1,2,3)
       end
test (generic function with 1 method)

julia> test(Int[], ())
(1, 2, 3)

Unlike the previous code, which simply performs type-assertion, this one does type-conversion.

julia> test(Float64[], ())
(1.0, 2.0, 3.0)
2 Likes