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!newsfeed5.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.009 X-Spam-Evidence: '*H*': 0.98; '*S*': 0.00; 'python.': 0.02; "(i'd": 0.09; '__future__': 0.09; 'received:mail-qc0-f174.google.com': 0.09; 'language': 0.14; '"from': 0.16; 'debug)': 0.16; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'type),': 0.16; 'wed,': 0.16; 'wrote:': 0.17; 'variables': 0.17; 'discussion': 0.20; 'variable': 0.20; 'import': 0.21; 'work.': 0.23; 'header:In-Reply-To:1': 0.25; 'am,': 0.27; 'checking': 0.27; 'message-id:@mail.gmail.com': 0.27; 'options': 0.27; "doesn't": 0.28; "i'm": 0.29; '(including': 0.30; "skip:' 10": 0.30; 'code': 0.31; '(and': 0.32; 'could': 0.32; "aren't": 0.33; 'to:addr :python-list': 0.33; 'that,': 0.34; "can't": 0.34; 'received:google.com': 0.34; 'continue': 0.35; 'received:209.85': 0.35; 'there': 0.35; 'ability': 0.36; 'but': 0.36; 'skip:v 20': 0.37; 'received:209': 0.37; 'received:209.85.216': 0.37; 'subject:: ': 0.38; 'easier': 0.38; 'some': 0.38; 'to:addr:python.org': 0.39; 'skip:" 10': 0.40; 'header:Received:5': 0.40; 'subject:, ': 0.61; 'strange': 0.62; 'making': 0.64; 'jul': 0.65; 'kat': 0.91; 'subject:skip:E 10': 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 :content-type; bh=j+EitU2G15uMnx0BP3s85geftMUZG/VlgmD72mncy90=; b=jc+x8GenMxYBsbJeh50dokQ8UNzOmaZzDX5csl90CP6hB2zPnFfS5CrWGtJjaROZBj heZmMLCjtOOlitZsIQZbDdJTNvbAJXlIEDI7pZEhIruLmBQ2O8AX36jb6vbyphPtgdGe wRhtbKxl3bPiagkv982TdAixwPAt0QdsPWo9r4SakH4DIR8wxaWHSEA9GPnVGGvFOpow 16GxOmA0HQpDEgjsSz2YLUjtqd8+rZVVXyx3FRCO/eE+lg2ibwOVYuT60FgJJ1/zqCrY QAtoNNC8sukG2EB7ga5e6RwniojIAFNC3cI9IiA0XevIgwnCpL7SOxBqPx/TheUgQbWv EmPA== MIME-Version: 1.0 In-Reply-To: References: <3vnfd9-343.ln1@satorlaser.homedns.org> <-8SdnVrXGqie25jNnZ2dnUVZ7qKdnZ2d@bt.com> Date: Wed, 18 Jul 2012 04:01:02 +1000 Subject: Re: Encapsulation, inheritance and polymorphism 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: 18 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1342548066 news.xs4all.nl 6872 [2001:888:2000:d::a6]:47415 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:25525 On Wed, Jul 18, 2012 at 12:23 AM, Lipska the Kat wrote: > Well 'type-bondage' is a strange way of thinking about compile time type > checking and making code easier to read (and therefor debug) but > I'm not about to get into some religious war about declaring a variables > type. There are options for that, but they aren't Python. (I'd like to see a "from __future__ import variable_declarations", but it doesn't seem to work. Yet.) If you're interested, I could tell you about a language that has a lot of what you're looking for (including polymorphism and even the ability to declare a variable that can contain "non-negative integer" as a type), but it's off-topic for the forum. However, I can't email you, as lipskathekat.com doesn't seem to exist... Email me privately if you're interested, we can continue the discussion off-list. ChrisA