Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #95836
| From | Marko Rauhamaa <marko@pacujo.net> |
|---|---|
| Newsgroups | comp.lang.python |
| Subject | Re: Why Python is not both an interpreter and a compiler? |
| Date | 2015-09-01 19:20 +0300 |
| Organization | A noiseless patient Spider |
| Message-ID | <87io7uun4s.fsf@elektro.pacujo.net> (permalink) |
| References | <3e541d13-bc86-456c-8590-4ffd1af9cfd0@googlegroups.com> <mailman.16.1441021308.23514.python-list@python.org> <87twrftw4w.fsf@elektro.pacujo.net> <a1dc8c59-e5a8-4672-afde-49416bbee76a@googlegroups.com> <55e5c220$0$1641$c3e8da3$5496439d@news.astraweb.com> |
Steven D'Aprano <steve@pearwood.info>: > I believe that Marko is wrong. It is not so easy to compile Python to > machine language for real machines. That's why the compiler targets a > virtual machine instead. Somehow Guile manages it even though Scheme is at least as dynamic a language as Python. I never said a compiler would translate Python to (analogous) machine language. I said you could easily turn CPython into a dynamic library (run-time environment) and write a small bootstrapper that you package into an executable archive with the Python code (whether .py or .pyc). What results is a single executable that you can run analogously to any other command. In fact, the shebang notation turns any single .py file into such an executable. The problem is if you break your program into modules. Java, of course, solved a similar problem with .jar files (but still wouldn't jump over the final hurdle of making the .jar files executable). Marko
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Why Python is not both an interpreter and a compiler? Mahan Marwat <mahanmarwat@gmail.com> - 2015-08-31 01:35 -0700
Re: Why Python is not both an interpreter and a compiler? Chris Angelico <rosuav@gmail.com> - 2015-08-31 18:49 +1000
Re: Why Python is not both an interpreter and a compiler? Cameron Simpson <cs@zip.com.au> - 2015-08-31 19:59 +1000
Re: Why Python is not both an interpreter and a compiler? Ben Finney <ben+python@benfinney.id.au> - 2015-08-31 21:41 +1000
Re: Why Python is not both an interpreter and a compiler? Marko Rauhamaa <marko@pacujo.net> - 2015-08-31 16:39 +0300
Re: Why Python is not both an interpreter and a compiler? Mahan Marwat <mahanmarwat@gmail.com> - 2015-08-31 10:48 -0700
Re: Why Python is not both an interpreter and a compiler? Emile van Sebille <emile@fenx.com> - 2015-08-31 10:56 -0700
Re: Why Python is not both an interpreter and a compiler? Ben Finney <ben+python@benfinney.id.au> - 2015-09-01 09:15 +1000
Re: Why Python is not both an interpreter and a compiler? Luca Menegotto <otlucaDELETE@DELETEyahoo.it> - 2015-09-01 07:45 +0200
Re: Why Python is not both an interpreter and a compiler? Ian Kelly <ian.g.kelly@gmail.com> - 2015-09-01 11:21 -0600
Re: Why Python is not both an interpreter and a compiler? Laura Creighton <lac@openend.se> - 2015-09-01 09:51 +0200
Re: Why Python is not both an interpreter and a compiler? Steven D'Aprano <steve@pearwood.info> - 2015-09-02 01:20 +1000
Re: Why Python is not both an interpreter and a compiler? Marko Rauhamaa <marko@pacujo.net> - 2015-09-01 19:20 +0300
Re: Why Python is not both an interpreter and a compiler? Chris Angelico <rosuav@gmail.com> - 2015-09-02 03:06 +1000
Re: Why Python is not both an interpreter and a compiler? Laura Creighton <lac@openend.se> - 2015-09-01 19:33 +0200
Re: Why Python is not both an interpreter and a compiler? Marko Rauhamaa <marko@pacujo.net> - 2015-09-01 23:08 +0300
Re: Why Python is not both an interpreter and a compiler? Chris Angelico <rosuav@gmail.com> - 2015-09-02 10:50 +1000
Re: Why Python is not both an interpreter and a compiler? Laura Creighton <lac@openend.se> - 2015-09-02 09:09 +0200
Re: Why Python is not both an interpreter and a compiler? wxjmfauth@gmail.com - 2015-09-02 01:25 -0700
Re: Why Python is not both an interpreter and a compiler? Laura Creighton <lac@openend.se> - 2015-09-01 19:52 +0200
Re: Why Python is not both an interpreter and a compiler? Steven D'Aprano <steve@pearwood.info> - 2015-09-02 12:49 +1000
Re: Why Python is not both an interpreter and a compiler? Marko Rauhamaa <marko@pacujo.net> - 2015-09-02 06:58 +0300
Re: Why Python is not both an interpreter and a compiler? Jussi Piitulainen <harvesting@makes.address.invalid> - 2015-09-02 08:59 +0300
Re: Why Python is not both an interpreter and a compiler? Michael Torrie <torriem@gmail.com> - 2015-09-01 21:46 -0600
csiph-web