Mojo as a Python superset

Hi Joey,

Thank you for writing such a thoughtful post. As you mention, it is still a goal for Mojo to grow into an effective superset of Python, it will just take time. [1] Many of the design decisions we are making are keeping this goal in mind, we are just not prioritizing work to enable this.

Upthread the old object type is brought up as an example - this is a great example of the “bad thing” that was happening before we made this decision to focus. Several people (myself included) wanted to add Pythonic support, but the core type system wasn’t ready yet. As a consequence of this, things like object were implemented in entirely the wrong way. This led to an unending stream of bug reports and things we just couldn’t fix, because we didn’t have the infra to do so.

It is much better for us to focus on building out the core type system, get it settled, then build on top of it. This approach allows us to avoid creating language tech debt and exposing a false promise of compatibility far ahead of when it will actually work well.

-Chris

[1] FWIW, I think that people overindex on what “superset” means. C++ is considered a superset of C even though it isn’t literally source compatible. I believe that Mojo will end up with the same relationship to Python in the fullness of time.

8 Likes