Skip to content

Deepcopy fails for an edge case. #57883

@AstitvaAggarwal

Description

@AstitvaAggarwal
using Test
struct test_struct
    a::Vector{Float64}
    b::Int64

    function test_struct()
        return new()
    end
end

object=test_struct()
copy=deepcopy(object)
@test object==copy       # Fails

And a more general edge case as objects from structs of the kind :

struct TestStruct3
    a::Vector{Float64}
    b::Vector{Float64}
    c::Int64
    TestStruct3() = new([0.0])
end

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