Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!goblin2!goblin.stu.neva.ru!newsfeed.xs4all.nl!newsfeed4.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; 'subject:not': 0.03; 'widely': 0.05; '*not*': 0.07; 'definitions.': 0.07; 'differently': 0.07; 'defines': 0.09; 'objects,': 0.09; 'oop': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'subject:instance': 0.09; 'python': 0.11; 'def': 0.12; 'language.': 0.14; 'argument:': 0.16; 'inheritance': 0.16; 'positional': 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'says...': 0.16; 'subject:)?': 0.16; 'subject:object': 0.16; 'term.': 0.16; 'think.': 0.16; 'typeerror:': 0.16; 'wrote:': 0.18; 'trying': 0.19; 'slightly': 0.19; '>>>': 0.22; 'rules': 0.22; 'header:User-Agent:1': 0.23; 'certainly': 0.24; 'oriented': 0.24; 'received:comcast.net': 0.24; 'class.': 0.26; 'pass': 0.26; 'defined': 0.27; 'header:X -Complaints-To:1': 0.27; 'header:In-Reply-To:1': 0.27; "doesn't": 0.30; "i'm": 0.30; 'class': 0.32; 'not.': 0.33; 'maybe': 0.34; 'subject: (': 0.35; 'classes': 0.35; 'common': 0.35; 'but': 0.35; 'described': 0.36; 'object,': 0.36; 'doing': 0.36; 'possible': 0.36; 'so,': 0.37; 'expressed': 0.37; 'being': 0.38; 'to:addr :python-list': 0.38; 'pm,': 0.38; 'does': 0.39; 'realize': 0.39; 'to:addr:python.org': 0.39; 'received:org': 0.40; 'is.': 0.60; 'act': 0.63; 'our': 0.64; 'different': 0.65; 'charset:windows-1252': 0.65; 'capable': 0.67; 'believe': 0.68; 'realized': 0.68; 'containing': 0.69; 'article': 0.77; '"not': 0.84; 'mistake': 0.91; 'whereas': 0.91 X-Injected-Via-Gmane: http://gmane.org/ To: python-list@python.org From: Ned Batchelder Subject: Re: An object is an instance (or not)? Date: Tue, 27 Jan 2015 21:21:15 -0500 References: Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Gmane-NNTP-Posting-Host: c-50-133-228-126.hsd1.ma.comcast.net User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:31.0) Gecko/20100101 Thunderbird/31.4.0 In-Reply-To: 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: 55 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1422411685 news.xs4all.nl 2857 [2001:888:2000:d::a6]:33775 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:84706 On 1/27/15 7:17 PM, Mario Figueiredo wrote: > In article , > ned@nedbatchelder.com says... >> >> A common mistake is to believe that "OOP" is a well-defined term. It's >> not it's a collection of ideas that are expressed slightly differently >> in each language. > > A common mistake is thinking just because OOP has different > implementations, it doesn't have a cohesive set of well described rules > and its own well defined terminology. I know you think that it has well described rules and terminology. But take a look at this discussion, and maybe realize that the terms are not as well-defined, or certainly not as widely accepted as you think. Do you have a reference that defines these terms? > >> I don't know what a "not fully realized object" is. > > A fully realized object, in an object oriented paradigm, is an object > containing or pointing to data and the methods to act on that data. It's > an instance of a class. > > A *not* fully realized object is possible in Python, since Classes are > first-class objects, despite not being able to participate in OOP. >> >> What does "participate in OOP" mean? > > Means the object is capable of participating in inheritance and/or > polymorphism. An instance of an object is capable of doing so, per its > class definitions. Whereas a Python class object is not. > > >>> class Master: > def func(self): > pass > > >>> class Sub(Master): > pass > > >>> Sub.func() > TypeError: func() missing 1 required positional argument: 'self' > But somehow I think you knew the answer to all these questions and were > instead being snarky. I am not being snarky, I'm trying to understand where our mutual incomprehension lies. -- Ned Batchelder, http://nedbatchelder.com