Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!news.albasani.net!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: Gregory Ewing Newsgroups: comp.lang.python Subject: Re: Why won't this decorator work? Date: Sun, 03 Jul 2011 16:14:25 +1200 Lines: 14 Message-ID: <97a8l3F39sU1@mid.individual.net> References: <8b8c3ca2-ae36-4009-842e-1dc90fb01b65@ct4g2000vbb.googlegroups.com> <98cca0c2-8d4f-4313-abed-3f34fa165c6d@u28g2000yqf.googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: individual.net GwhTdrurAAQilM5K4JCQTQ70d3A7s8GIDxYnUOP61rEAzl+Ys/ Cancel-Lock: sha1:FP6779P2tvE9yWewkB2RHhBhnvE= User-Agent: Mozilla Thunderbird 1.0.5 (Macintosh/20050711) X-Accept-Language: en-us, en In-Reply-To: Xref: x330-a1.tempe.blueboxinc.net comp.lang.python:8723 Ian Kelly wrote: > If it's not a callable, then the result > will just be that something non-callable is bound to the "roll_die" > name -- which could be useful, but is probably a bad idea in general. There are legitimate uses -- for example, the following is a convenient way of creating a read-only property: @property def foo(self): return self.calculate_value_of_foo() -- Greg