Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Need compare between metaclass and internal contents of classcell in __build_class__ #3865

Open
Snowapril opened this issue Jul 10, 2022 · 1 comment

Comments

@Snowapril
Copy link
Contributor

Feature

https://github.com/RustPython/RustPython/blob/main/vm/src/stdlib/builtins.rs#L899-L919
We should compare between class (invoked by metaclass) and classcell's internal contents before exiting __build_class__
At now we manually set classcell's internal contents with class, but this should be done in type.__new__

Python Documentation

Related test cases

  • test_super.py
    • test___classcell___overwrite
    • test___classcell___missing
    • test___classcell___wrong_cell
    • test___class___new
    • test___class___delayed
@Snowapril Snowapril changed the title Need compare between metaclass and class of classcell in __build_class__ Need compare between metaclass and internal contents of classcell in __build_class__ Jul 10, 2022
@youknowone
Copy link
Member

youknowone commented Feb 25, 2023

#3986 maybe related but not solved yet

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants