Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #33117

Re: Method default argument whose type is the class not yet defined

References <k7ma5c$qdk$1@speranza.aioe.org> <509efbb6$0$29980$c3e8da3$5496439d@news.astraweb.com> <CAPTjJmqz654F4QZmi+6K0ExT0oSazUn-txupSkOv1dy5eEhPqg@mail.gmail.com> <mailman.3549.1352601828.27098.python-list@python.org> <roy-2CDC35.21534210112012@news.panix.com>
From Ian Kelly <ian.g.kelly@gmail.com>
Date 2012-11-10 23:43 -0700
Subject Re: Method default argument whose type is the class not yet defined
Newsgroups comp.lang.python
Message-ID <mailman.3551.1352616258.27098.python-list@python.org> (permalink)

Show all headers | View raw


On Sat, Nov 10, 2012 at 7:53 PM, Roy Smith <roy@panix.com> wrote:
> In article <mailman.3549.1352601828.27098.python-list@python.org>,
>  Ian Kelly <ian.g.kelly@gmail.com> wrote:
>
>> On Sat, Nov 10, 2012 at 7:13 PM, Chris Angelico <rosuav@gmail.com> wrote:
>> > I would not assume that. The origin is a point, just like any other.
>> > With a Line class, you could deem a zero-length line to be like a
>> > zero-element list, but Point(0,0) is more like the tuple (0,0) which
>> > is definitely True.
>>
>> It's more like the number 0 than the tuple (0,0).
>>
>> 0 is the origin on a 1-dimensional number line.
>> (0,0) is the origin on a 2-dimensional number plane.
>
>> In fact, it might be pointed out that Point(0, 0) is a generalization
>> of 0+0j, which is equal to 0.
>
>
> If (0,0) is the origin on a plane, then (0,) should be the origin on a
> line.  If you consider 0 + 0j to be the origin of a plane, then 0 is the
> origin of a line.  Either way is plausible, but you need to be
> consistent.

Where I wrote "(0,0) is the origin" above I was not referring to a
point, not a tuple, but I can see how that was confusing.

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Method default argument whose type is the class not yet defined Jennie <nameDOTportua@gmail.com> - 2012-11-10 20:33 +0100
  Re: Method default argument whose type is the class not yet defined Chris Angelico <rosuav@gmail.com> - 2012-11-11 06:56 +1100
  Re: Method default argument whose type is the class not yet defined Terry Reedy <tjreedy@udel.edu> - 2012-11-10 15:29 -0500
    Re: Method default argument whose type is the class not yet defined Jennie <nameDOTportua@gmail.com> - 2012-11-10 21:51 +0100
      Re: Method default argument whose type is the class not yet defined Dave Angel <d@davea.name> - 2012-11-10 17:30 -0500
    Re: Method default argument whose type is the class not yet defined Jennie <marco.buttu@gmail.com> - 2012-11-10 21:51 +0100
  Re: Method default argument whose type is the class not yet defined Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2012-11-11 01:13 +0000
    Re: Method default argument whose type is the class not yet defined Chris Angelico <rosuav@gmail.com> - 2012-11-11 13:13 +1100
    Re: Method default argument whose type is the class not yet defined Ian Kelly <ian.g.kelly@gmail.com> - 2012-11-10 19:43 -0700
      Re: Method default argument whose type is the class not yet defined Roy Smith <roy@panix.com> - 2012-11-10 21:53 -0500
        Re: Method default argument whose type is the class not yet defined Ian Kelly <ian.g.kelly@gmail.com> - 2012-11-10 23:43 -0700
        Re: Method default argument whose type is the class not yet defined Ian Kelly <ian.g.kelly@gmail.com> - 2012-11-10 23:45 -0700
    Re: Method default argument whose type is the class not yet defined Chris Angelico <rosuav@gmail.com> - 2012-11-11 13:47 +1100
    Re: Method default argument whose type is the class not yet defined Oscar Benjamin <oscar.j.benjamin@gmail.com> - 2012-11-11 14:21 +0000
      Re: Method default argument whose type is the class not yet defined Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2012-11-11 22:31 +0000
        Re: Method default argument whose type is the class not yet defined Oscar Benjamin <oscar.j.benjamin@gmail.com> - 2012-11-12 00:31 +0000
          Re: Method default argument whose type is the class not yet defined Steve Howell <showell30@yahoo.com> - 2012-11-11 16:56 -0800
          Re: Method default argument whose type is the class not yet defined Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2012-11-12 04:46 +0000
        Re: Method default argument whose type is the class not yet defined Mark Lawrence <breamoreboy@yahoo.co.uk> - 2012-11-12 01:10 +0000
          Re: Method default argument whose type is the class not yet defined Roy Smith <roy@panix.com> - 2012-11-11 20:15 -0500
            Re: Method default argument whose type is the class not yet defined Mark Lawrence <breamoreboy@yahoo.co.uk> - 2012-11-12 01:35 +0000
        Re: Method default argument whose type is the class not yet defined Oscar Benjamin <oscar.j.benjamin@gmail.com> - 2012-11-12 01:18 +0000
          Re: Method default argument whose type is the class not yet defined Roy Smith <roy@panix.com> - 2012-11-11 20:34 -0500
        Re: Method default argument whose type is the class not yet defined Mark Lawrence <breamoreboy@yahoo.co.uk> - 2012-11-12 01:29 +0000
        Re: Method default argument whose type is the class not yet defined Oscar Benjamin <oscar.j.benjamin@gmail.com> - 2012-11-12 01:50 +0000
  Re: Method default argument whose type is the class not yet defined Oscar Benjamin <oscar.j.benjamin@gmail.com> - 2012-11-11 01:23 +0000
  Re: Method default argument whose type is the class not yet defined Steve Howell <showell30@yahoo.com> - 2012-11-11 16:32 -0800

csiph-web