Skip to content

[BUG] type_parameters with mixed unnamed and named positions is not inferrable #21

@mtfishman

Description

@mtfishman
julia> @code_warntype type_parameters.(Matrix{Float64}, (eltype, 2))
MethodInstance for (::var"##dotfunction#232#1")(::Type{Matrix{Float64}}, ::Tuple{typeof(eltype), Int64})
  from (::var"##dotfunction#232#1")(x1, x2) @ Main none:0
Arguments
  #self#::Core.Const(var"##dotfunction#232#1"())
  x1::Core.Const(Matrix{Float64})
  x2::Tuple{typeof(eltype), Int64}
Body::Tuple{Any, Any}
1%1 = Base.broadcasted(Main.type_parameters, x1, x2)::Base.Broadcast.Broadcasted{Base.Broadcast.Style{Tuple}, Nothing, typeof(type_parameters), Tuple{Base.RefValue{Type{Matrix{Float64}}}, Tuple{typeof(eltype), Int64}}}
│   %2 = Base.materialize(%1)::Tuple{Any, Any}
└──      return %2

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions