Skip to content

Support copy constructor for TypedDict #2738

Closed
@davidfstr

Description

@davidfstr

It should be possible to copy a TypedDict via a copy constructor like:

point2 = Point(point1)

Currently this is rejected by the type checker.


It may also be desirable to support the following:

point2d = Point2D(point3d)

...although I'd have to think about whether this is actually typesafe and consistent.


Suggested tags for this issue: feature, topic-typed-dict

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions