News for hackers. Stuff that matters.
Re:Show HN: Cannoli – A compiler for a subset of Python writ... by welder on Thursday May 17, 2018 @04:42PM (#17095494)
This could be used to ditch the Python interpreter and distribute Python binaries for Win/Linux/Mac. When will standard library, exceptions, and inheritance support be added?
Re:Show HN: Cannoli – A compiler for a subset of Python writ... by halflings on Thursday May 17, 2018 @05:27PM (#17096071)
Probably never. This is a subset of Python that would break most libraries.

The author says that this is a research project, and adding the standard library (if possible at all) would be a humongus task by itself.

Re:Show HN: Cannoli – A compiler for a subset of Python writ... by yorwba on Thursday May 17, 2018 @10:54PM (#17098326)
A large part of the Python standard library is actually written in Python itself. You can even use inspect.getsource to look at the source of inspect.getsource itself.

So if you can already compile arbitrary Python, you only need to reimplement the parts that are written in C, or maybe just rewrite them to use a different FFI API.

Re:Show HN: Cannoli – A compiler for a subset of Python writ... by halflings on Friday May 18, 2018 @04:14AM (#17099546)
It can't compile arbitrary Python, it's only a subset of Python (removing some of the dynamic features that might be used in the standard library).