On Mon, 04 Mar 2013 16:36:36 +, Grant Edwards wrote:
> On 2013-02-28, kramer65 wrote:
>
>> I'm using Python for a while now and I love it. There is just one thing
>> I cannot understand. There are compilers for languages like C and C++.
>> why is it impossible to create a compiler that can c
On Mar 4, 2013 3:02 PM, "CM" wrote:
>
>
> > The main issue is that python has dynamic typing. The type of object
> > that is referenced by a particular name can vary, and there's no way
> > (in general) to know at compile time what the type of object "foo" is.
> >
> > That makes generating object
On Tue, Mar 5, 2013 at 9:55 AM, CM wrote:
>
>> The main issue is that python has dynamic typing. The type of object
>> that is referenced by a particular name can vary, and there's no way
>> (in general) to know at compile time what the type of object "foo" is.
>>
>> That makes generating object
On 3/4/2013 5:55 PM, CM wrote:
Could you help me understand this better? For example, if you
have this line in the Python program:
foo = 'some text'
bar = {'apple':'fruit'}
If the interpreter can determine at runtime that foo is a string
and bar is a dict, why can't the compiler figure that o
On Tuesday, March 5, 2013 6:55:06 AM UTC+8, CM wrote:
> > The main issue is that python has dynamic typing. The type of object
>
> > that is referenced by a particular name can vary, and there's no way
>
> > (in general) to know at compile time what the type of object "foo" is.
>
> >
>
> > Tha
> The main issue is that python has dynamic typing. The type of object
> that is referenced by a particular name can vary, and there's no way
> (in general) to know at compile time what the type of object "foo" is.
>
> That makes generating object code to manipulate "foo" very difficult.
Could y
On 2013-02-28, kramer65 wrote:
> I'm using Python for a while now and I love it. There is just one
> thing I cannot understand. There are compilers for languages like C
> and C++. why is it impossible to create a compiler that can compile
> Python code to machinecode?
The main issue is that pyth
On Fri, 01 Mar 2013 08:48:34 +0100, Stefan Behnel wrote:
> Steven D'Aprano, 01.03.2013 04:47:
>> On Thu, 28 Feb 2013 22:03:09 +0100, Stefan Behnel wrote:
>>
>>> The most widely used static Python compiler is Cython
>>
>> Cython is not a Python compiler. Cython code will not run in a vanilla
>> P
Steven D'Aprano, 01.03.2013 04:47:
> On Thu, 28 Feb 2013 22:03:09 +0100, Stefan Behnel wrote:
>
>> The most widely used static Python compiler is Cython
>
> Cython is not a Python compiler. Cython code will not run in a vanilla
> Python implementation. It has different keywords and syntax, e.g.:
kramer65於 2013年3月1日星期五UTC+8上午4時25分07秒寫道:
> Hello,
>
>
>
> I'm using Python for a while now and I love it. There is just one thing I
> cannot understand. There are compilers for languages like C and C++. why is
> it impossible to create a compiler that can compile Python code to
> machinecode?
On Mar 1, 6:25 am, kramer65 wrote:
> There are compilers for languages like C and C++. why
> is it impossible to create a compiler that can compile
> Python code to machinecode?
This is a nice site list a lot of current approaches to that subject:
http://compilers.pydata.org/
--
http://mail.pyt
On Mar 1, 1:47 pm, Steven D'Aprano wrote:
> Cython is not a Python compiler. Cython code will not run in a vanilla
> Python implementation. It has different keywords and syntax, e.g.:
>
> cdef inline int func(double num):
> ...
>
> which gives SyntaxError in a Python compiler.
Cython has had
On Thu, 28 Feb 2013 12:25:07 -0800, kramer65 wrote:
> Hello,
>
> I'm using Python for a while now and I love it. There is just one thing
> I cannot understand. There are compilers for languages like C and C++.
> why is it impossible to create a compiler that can compile Python code
> to machineco
On Thu, 28 Feb 2013 22:03:09 +0100, Stefan Behnel wrote:
> The most widely used static Python compiler is Cython
Cython is not a Python compiler. Cython code will not run in a vanilla
Python implementation. It has different keywords and syntax, e.g.:
cdef inline int func(double num):
...
On Thu, 28 Feb 2013 15:50:00 -0500, Matty Sarro wrote:
> Python is an interpreted language, not a compiled language.
Actually, *languages* are neither interpreted nor compiled. A language is
an abstract description of behaviour and syntax. Whether something is
interpreted or compiled or a mixtu
On Thu, 28 Feb 2013 12:25:07 -0800, kramer65 wrote:
> I'm using Python for a while now and I love it. There is just one thing
> I cannot understand. There are compilers for languages like C and C++.
> why is it impossible to create a compiler that can compile Python code
> to machinecode?
It's no
The subject line is wrong. There are multiple compilers. Someone just
listed some of them today in another post.
On 2/28/2013 3:50 PM, Matty Sarro wrote:
Python is an interpreted language, not a compiled language.
A language is just a language. Implementations are implementations*.
That asid
On do, feb 28, 2013 at 12:25:07pm -0800, kramer65 wrote:
> Hello,
>
> I'm using Python for a while now and I love it. There is just one thing I
> cannot understand. There are compilers for languages like C and C++. why is
> it impossible to create a compiler that can compile Python code to
> ma
> I'm using Python for a while now and I love it. There is just one thing I
> cannot understand. There are compilers for languages like C and C++. why is
> it impossible to create a compiler that can compile Python code to
> machinecode?
Not exactly what you describe, but have you checked out PyPy
On 02/28/2013 03:25 PM, kramer65 wrote:
Hello,
I'm using Python for a while now and I love it. There is just one thing I
cannot understand. There are compilers for languages like C and C++. why is it
impossible to create a compiler that can compile Python code to machinecode?
My reasoning is
Stefan Behnel, 28.02.2013 22:03:
> there are also a couple of projects that do
> dynamic runtime compilation, most notably PyPy and Numba.
Oh, and HotPy, I keep forgetting about that.
> You may want to take a look at the Python implementations page,
> specifically the list of Python compilers:
>
On Fri, Mar 1, 2013 at 7:50 AM, Matty Sarro wrote:
> C (your example) was intended for very low level programming, things like
> operating systems, device drivers, networking stacks, where the speed of a
> compiled executable and direct access to hardware was a necessity. That's
> what Dennis Ritc
kramer65, 28.02.2013 21:25:
> I'm using Python for a while now and I love it. There is just one thing
> I cannot understand. There are compilers for languages like C and C++.
> why is it impossible to create a compiler that can compile Python code
> to machinecode?
All projects that implement such
Python is an interpreted language, not a compiled language. This is
actually a good thing! What it means is that there is a "scripting engine"
(we just call it the interpreter) that actually executes everything for
you. That means that any operating system that has an interpreter written
for it is
Hello,
I'm using Python for a while now and I love it. There is just one thing I
cannot understand. There are compilers for languages like C and C++. why is it
impossible to create a compiler that can compile Python code to machinecode?
My reasoning is as follows:
When GCC compiles a program wr
25 matches
Mail list logo