Are there other languages ​​designed for the Python virtual machine?

It seems that a fairly significant part of the new languages ​​that come out are launched either on the JVM or the CLR. It is supposedly high in the list of advantages for this: 1) access to libraries and 2) portability, especially with Java. Has anyone tried to do the same for Python? The closest I can find is this :

Why lucky, they once hacked together a script that would compile Ruby code into Python bytecode. I remember that it worked well for simple ruby ​​scripts. You can look at the sources to find out how he did it.

EDIT: So what he does is let Ruby VM generate Ruby byte code than translate that byte code into Python. It may be interesting to see how Python bytecode is assembled :)

BTW, here's an interesting question about whether Python has a “virtual machine” in the same sense as Java, or an “interpreter”. All in all, I think for the purposes of this question it is wise to consider Python in order to have a virtual machine.

+4
source share

Source: https://habr.com/ru/post/1536111/


All Articles