Path: csiph.com!usenet.pasdenom.info!weretis.net!feeder1.news.weretis.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.xs4all.nl!newsfeed2.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.000 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'python,': 0.02; 'syntax': 0.04; 'interpreter': 0.05; 'sufficient': 0.05; 'compiler': 0.07; 'definitions': 0.07; 'intermediate': 0.07; 'strict': 0.07; '"c"': 0.09; 'interpreted': 0.09; 'mastery': 0.09; 'runtime': 0.09; 'subject: [': 0.09; 'subtle': 0.09; 'cc:addr:python-list': 0.11; 'language.': 0.14; 'fuzzy': 0.16; 'language?': 0.16; 'lexical': 0.16; 'reasonable.': 0.16; 'requested.': 0.16; 'run-time.': 0.16; 'targeting': 0.16; 'think.': 0.16; 'to:addr:pearwood.info': 0.16; 'to:addr:steve+comp.lang.python': 0.16; "to:name:steven d'aprano": 0.16; 'extensions': 0.16; 'for?': 0.16; 'language': 0.16; 'machine': 0.22; '>>>': 0.22; 'cc:addr:python.org': 0.22; 'this?': 0.23; 'bytes': 0.24; 'days,': 0.24; "shouldn't": 0.24; 'question': 0.24; 'cc:2**0': 0.24; 'cc:no real name:2**0': 0.24; "i've": 0.25; 'compiled': 0.26; 'extension': 0.26; 'gets': 0.27; 'header:In- Reply-To:1': 0.27; 'feature': 0.29; 'message-id:@mail.gmail.com': 0.30; 'code': 0.31; 'file': 0.32; 'there.': 0.32; 'probably': 0.32; 'agreed': 0.32; 'languages': 0.32; 'quite': 0.32; 'computer.': 0.33; 'actual': 0.34; 'definition': 0.35; 'but': 0.35; 'received:google.com': 0.35; 'sequence': 0.36; 'up!': 0.36; 'possible': 0.36; 'example,': 0.37; 'virtual': 0.37; 'architecture': 0.38; 'ends': 0.38; 'mapping': 0.38; 'files': 0.38; 'rather': 0.38; 'that,': 0.38; 'skip:p 20': 0.39; 'even': 0.60; 'most': 0.60; 'personal': 0.63; 'face': 0.64; 'therefore,': 0.64; 'become': 0.64; 'more': 0.64; '(that': 0.65; 'within': 0.65; 'between': 0.67; 'actually,': 0.84; 'subject:gets': 0.84; 'universally': 0.84; 'careful': 0.91; 'notion': 0.91; 'stood': 0.93; 'washington': 0.93; 'yourself,': 0.95 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=R1XTiUeyIaKn0DCKc3E6UVfQG2t/GvvdV2YqV+QFEBQ=; b=T/Hq0Kc3VG9s5xpQKpbn6+vu8n36wyu0l2MguugWBZvQ1hWf9WIwaV+4CSz+reEfV1 qpDeHtOsp1uJaLxXJFm1bmMtTl/Ti/bw21Cw2XsNiUB6PyrpKiHbWwnQIOmqnmAHZjJ1 IcBvLrA2V9HHg5UwZpDZHwXtzeIYUBXowDh80suqDMCXU9mdY+WmTkd22ssOSATntxb9 iBuO+V6qz2DUm9TdJXCZlE7Ca/X2kik+5bRHhXJ7IWIgPX6Nfp2jbYSkcGkKPAtPw4KV e4VeyNoH+AsrQfvDM5Ms0xRdQQ0VCS/YlXICiQuyrO3qYhhYCq7zyDMoDQYPj6He4XeF j3UA== MIME-Version: 1.0 X-Received: by 10.180.72.227 with SMTP id g3mr3504150wiv.1.1371411119079; Sun, 16 Jun 2013 12:31:59 -0700 (PDT) In-Reply-To: <51bdaa78$0$29966$c3e8da3$5496439d@news.astraweb.com> References: <2bc90d3b-09c2-4315-9357-ff7f039465e0@googlegroups.com> <51b926a3$0$29997$c3e8da3$5496439d@news.astraweb.com> <51ba6e92$0$29997$c3e8da3$5496439d@news.astraweb.com> <51bb454c$0$29997$c3e8da3$5496439d@news.astraweb.com> <51bdaa78$0$29966$c3e8da3$5496439d@news.astraweb.com> Date: Sun, 16 Jun 2013 12:31:59 -0700 Subject: Re: Compiling vs interpreting [was Re: A certainl part of an if() structure never gets executed.] From: Mark Janssen To: "Steven D'Aprano" Content-Type: text/plain; charset=ISO-8859-1 Cc: python-list@python.org X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 46 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1371411127 news.xs4all.nl 15868 [2001:888:2000:d::a6]:47529 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:48471 >>> Whats the difference of "interpreting " to "compiling" ? >> >> OK, I give up! > > Actually, that's a more subtle question than most people think. Python, > for example, is a compiled language. (What did you think the "c" in > ".pyc" files stood for? and the compile() function>?) Careful there. This terminology is not agreed upon universally (that is, within the realm of academia where the notion of mastery exists), and unless you are citing an actual reference or publishing one yourself, then you may be adding more confusion than illumination. For example, I would say that it is an *interpreted language* that gets compiled at run-time. Some (*valid*) definitions of "compiler" mean a strict mapping from the language syntax and lexical definition to a sequence of bytes that can be fed to a (hardware not virtual) machine architecture to do perform what is requested. The face that an extension ends in the letter "c" is not sufficient evidence, since file extensions have no strict standard. > And these days, for many types of hardware, even machine-code is often > interpreted by a virtual machine on a chip. And even languages which > compile to machine-code often use an intermediate platform-independent > form rather than targeting pure machine-code. Do you have a reference for this? What language? > The line between compilers > and interpreters is quite fuzzy. It shouldn't be. What is fuzzy is the definition of "interpreter", however. The definition of compiler has only become fuzzy with the advent of the personal computer. > Probably the best definition I've seen for the difference between a > modern compiler and interpreter is this one: > > "...the distinguishing feature of interpreted languages is not that they > are not compiled, but that the compiler is part of the language runtime > and that, therefore, it is possible (and easy) to execute code generated > on the fly." That's reasonable. -- MarkJ Tacoma, Washington