Skip to content

Type instability in Folds.map #55

@msainsburydale

Description

@msainsburydale

Hi,

I recently posted an issue (see here) on the Julia discourse regarding Folds.jl. Reposting here for visibility.

I’ve noticed that the Folds version of map() seems to introduce type instability:

using Folds
f1(K::Integer) = map(identity, 1:K) 
f2(K::Integer) = Folds.map(identity, 1:K) 

@code_warntype f1(5)
@code_warntype f2(5)

Do you have any suggestions for how to address this? Thanks in advance.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions