Re: Byte-run: a Python interpreter written in Python

2017-01-13 Thread Ned Batchelder
On Friday, January 13, 2017 at 12:09:52 PM UTC-5, Ian wrote: > On Fri, Jan 13, 2017 at 3:46 AM, Steve D'Aprano > wrote: > > > > http://aosabook.org/en/500L/a-python-interpreter-written-in-python.html > > Neat. But not really surprising IMO that it can fit into 500 lines, > since it doesn't handle

Re: Byte-run: a Python interpreter written in Python

2017-01-13 Thread BartC
On 13/01/2017 18:47, Ian Kelly wrote: On Fri, Jan 13, 2017 at 11:07 AM, BartC wrote: Even when it turns out that the actual code on github is 1000 lines rather than 500! Maybe it grew a bit since the 500 lines was quoted. I assume they're excluding blank lines, comments and docstrings. And I

Re: Byte-run: a Python interpreter written in Python

2017-01-13 Thread Ian Kelly
On Fri, Jan 13, 2017 at 11:07 AM, BartC wrote: > Even when it turns out that the actual code on github is 1000 lines rather > than 500! Maybe it grew a bit since the 500 lines was quoted. I assume they're excluding blank lines, comments and docstrings. And I don't know whether the 500 lines is a

Re: Byte-run: a Python interpreter written in Python

2017-01-13 Thread BartC
On 13/01/2017 17:08, Ian Kelly wrote: On Fri, Jan 13, 2017 at 3:46 AM, Steve D'Aprano wrote: http://aosabook.org/en/500L/a-python-interpreter-written-in-python.html Neat. But not really surprising IMO that it can fit into 500 lines, If there are still 120 or so byte-codes, then that's just

Re: Byte-run: a Python interpreter written in Python

2017-01-13 Thread Ian Kelly
On Fri, Jan 13, 2017 at 3:46 AM, Steve D'Aprano wrote: > > http://aosabook.org/en/500L/a-python-interpreter-written-in-python.html Neat. But not really surprising IMO that it can fit into 500 lines, since it doesn't handle compiling Python into bytecode (which is the hard part) and doesn't includ

Byte-run: a Python interpreter written in Python

2017-01-13 Thread Steve D'Aprano
http://aosabook.org/en/500L/a-python-interpreter-written-in-python.html -- Steve “Cheer up,” they said, “things could be worse.” So I cheered up, and sure enough, things got worse. -- https://mail.python.org/mailman/listinfo/python-list