Path: csiph.com!usenet.pasdenom.info!gegeweb.org!de-l.enfer-du-nord.net!feeder1.enfer-du-nord.net!newsfeed.eweka.nl!eweka.nl!feeder3.eweka.nl!newsfeed.xs4all.nl!newsfeed6.news.xs4all.nl!xs4all!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; 'subject:Python': 0.05; 'interpreter.': 0.07; 'python': 0.09; 'dict': 0.09; 'insertion': 0.09; 'keyed': 0.09; 'pointers': 0.09; "wouldn't": 0.11; 'aug': 0.13; 'language': 0.14; '"x"': 0.16; 'driscoll': 0.16; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'pointers.': 0.16; 'subject:Objects': 0.16; 'third,': 0.16; 'variable.': 0.16; 'string': 0.17; 'wrote:': 0.17; 'variables': 0.17; '>>>': 0.18; 'variable': 0.20; 'bit': 0.21; 'received:209.85.214.174': 0.21; 'header:In-Reply-To:1': 0.25; 'looks': 0.26; 'possibly': 0.27; 'message-id:@mail.gmail.com': 0.27; 'fixed': 0.28; 'chris': 0.28; "d'aprano": 0.29; 'steven': 0.29; 'code': 0.31; 'implement': 0.32; 'addresses': 0.32; 'could': 0.32; "aren't": 0.33; 'to:addr:python-list': 0.33; 'received:google.com': 0.34; 'stores': 0.35; 'pm,': 0.35; 'received:209.85': 0.35; 'something': 0.35; 'there': 0.35; 'received:209': 0.37; 'subject:: ': 0.38; 'to:addr:python.org': 0.39; 'received:209.85.214': 0.39; 'build': 0.39; 'called': 0.39; 'where': 0.40; 'header:Received:5': 0.40; 'your': 0.60; 'stand': 0.61; 'more': 0.63; '26,': 0.65; 'difficulty': 0.65; 'else.': 0.65; 'technically': 0.91 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 :content-type; bh=kquQwerVBmqzVWMl8a/mkg5yXWdMQzs56PQas+mJwto=; b=RwY3IhG/wde6CccRYBgJw2c1wf/y9F+d2CrXqL+6ZjI6Uhjy7G4ny+CvSk5qD+WxIX HazSsou2VhCzXT6EWHF59E0eCTmGfxmt6CC18xE+aPMoDwEopnNcEmB6UYo0JklwPu02 hGyHmDS20tx+WH8QryJhZ8EtQeeXeB+KV5UbyBSuEhpy0Uqn2r5+Ys3aYudc/hQgL9wj vYxghDhDgWjhvR/MJem3LJ0InUDY0bBw/l2fesl5JRUtBruVA9ES856DYYXrDZ1c4XFH bqQMB5JTrBdfdd0iyGJXlrD8Tz1XPuPQ/VdpELL3s3nZRJ4WSjbTJIcCWrU3k6NFsY4f Kcog== MIME-Version: 1.0 In-Reply-To: <503a105b$0$6574$c3e8da3$5496439d@news.astraweb.com> References: <18409992-1e28-4721-8e64-60c69668da4e@googlegroups.com> <87d32i1ntc.fsf@benfinney.id.au> <7df4c317-7ad8-4158-900a-b52f19c3caf2@k9g2000pbr.googlegroups.com> <503750b9$0$6574$c3e8da3$5496439d@news.astraweb.com> <5039B813.8020603@cs.wisc.edu> <503a105b$0$6574$c3e8da3$5496439d@news.astraweb.com> Date: Sun, 26 Aug 2012 23:34:57 +1000 Subject: Re: Objects in Python From: Chris Angelico To: python-list@python.org Content-Type: text/plain; charset=ISO-8859-1 X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.12 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: 24 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1345988100 news.xs4all.nl 6950 [2001:888:2000:d::a6]:42077 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:27919 On Sun, Aug 26, 2012 at 10:02 PM, Steven D'Aprano wrote: > On Sun, 26 Aug 2012 16:22:05 +1000, Chris Angelico wrote: > >> On Sun, Aug 26, 2012 at 3:45 PM, Evan Driscoll >> wrote: >>> Third, and more wackily, you could technically create a C >>> implementation that works like Python, where it stores variables (whose >>> addresses aren't taken) in a dict keyed by name, and generates code >>> that on a variable access looks up the value by accessing that dict >>> using the name of the variable. >> >> That would be a reasonable way to build a C interactive interpreter. > > No it wouldn't. Without fixed addresses, the language wouldn't be able to > implement pointers. C without pointers isn't C, it is something else. > Possibly called Python :) The insertion of a single rule will do it. Let it stand that &x is the string "x" and there you are, out of your difficulty at once! Okay, that may be a bit of a fairy tale ending and completely illogical. ChrisA