Skip to content

use of rehash! in constructor #9

@StephenVavasis

Description

@StephenVavasis

I noticed the following snippet in ordered_dict.jl:

    function OrderedDict{K,V}(d::OrderedDict{K,V}) where {K,V}
        if d.ndel > 0
            rehash!(d)
        end
        @assert d.ndel == 0
        new{K,V}(copy(d.slots), copy(d.keys), copy(d.vals), 0)
    end

Isn't this a known source of bugs? See JuliaCollections/DataStructures.jl#335

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions