Skip to content

float(SVector) gives an MVector #247

Closed
@stevengj

Description

@stevengj
julia> float(SVector(0))
1-element MVector{1,Float64}:
 0.0

This is because it is calling base/float.jl, which calls convert(AbstractArray, ...) which calls similar, I think(?), but in this case it seems more useful to return an SVector?

Or is there a better way to promote an SVector to a float-based type, e.g. from Complex{Int} to Complex{Float}?

Metadata

Metadata

Assignees

No one assigned

    Labels

    featurefeatures and feature requestsgood first issueIssue which is likely easy to solveup for grabsImplement me, I'm yours!

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions