Skip to content

too many method matches for zeros(Type, ...) #5575

Closed
@simonster

Description

The underlying cause of #5559 is now fixed, but this was the immediate cause. Before 6002358:

julia> f() = zeros(Type[Float64][1], 1);

julia> code_typed(f, ())
1-element Array{Any,1}:
 :($(Expr(:lambda, {}, {{},{},{}}, quote  # none, line 1:
        return zeros(arrayref(getindex(Type,Float64)::Array{Type{T<:Top},1},1)::Type{T<:Top},1)::Array{T,1}
    end)))

After:

julia> f() = zeros(Type[Float64][1], 1);

julia> code_typed(f, ())
1-element Array{Any,1}:
 :($(Expr(:lambda, {}, {{},{},{}}, quote  # none, line 1:
        return zeros(arrayref(getindex(Type,Float64)::Array{Type{T<:Top},1},1)::Type{T<:Top},1)::AbstractArray{T,N}
    end)))

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

Labels

regressionRegression in behavior compared to a previous version

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions