boxed
boxed
MModular
Created by denden on 9/15/2023 in #questions
Will imported python modules eventually be compiled by Mojo instead of relying on the python env?
I would guess it's more of an aspirational long goal. There are a lot of big wins that can be had by not being straight python that they should target first. But ease of porting is a big goal yea, much bigger and important than syntactic superset.
10 replies
MModular
Created by denden on 9/15/2023 in #questions
Will imported python modules eventually be compiled by Mojo instead of relying on the python env?
meta classes for example are quite fiddly.. and walking the mro is also special... looking at local variables
10 replies
MModular
Created by denden on 9/15/2023 in #questions
Will imported python modules eventually be compiled by Mojo instead of relying on the python env?
Mojo is a looooong way from the goal of syntactic superset though. For example classes, and keyword arguments aren't supported. I don't think I have any python code I've written in the last 10 years that can run unmodified in mojo :P
10 replies
MModular
Created by denden on 9/15/2023 in #questions
Will imported python modules eventually be compiled by Mojo instead of relying on the python env?
Also note that "syntactic superset" doesn't neccessarily mean it will run all python code the same ;P
10 replies
MModular
Created by denden on 9/15/2023 in #questions
Will imported python modules eventually be compiled by Mojo instead of relying on the python env?
Just being a syntactic superset of Python isn't nearly enough. Part of the reason to target Python is the huge ecosystem of libs that are not python, most importantly C, C++ and Fortran libs with good python wrappers. Just compiling all the Python code (if that's even possible) wouldn't really help with that. Interop is the only way.
10 replies