Skip to content

Make ClassDef.metaclass an Expression instead of str #3847

Closed
@elazarg

Description

@elazarg

Currently the metaclass node is assumed to be a string. This is inconsistent, requires workarounds such as passing '<error>' from the parser to the semantic analysis phase, and makes it awkward to handle metaclasses that come from different contexts (as in python2).

Making it an Expression works cleanly as far as I can tell, and reduces code duplication.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions