Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!us.feeder.erje.net!bloom-beacon.mit.edu!bloom-beacon.mit.edu!panix!not-for-mail From: Grant Edwards Newsgroups: comp.lang.python Subject: Re: Decorators Date: Sat, 15 Nov 2014 15:32:01 +0000 (UTC) Organization: PANIX Public Access Internet and UNIX, NYC Lines: 23 Message-ID: References: <96c138e4-ab95-4e5f-a0c8-e696b5a926bb@googlegroups.com> <8761ehmnnt.fsf_-_@elektro.pacujo.net> <26dba8fd-e403-4129-ad57-11376eb807bd@googlegroups.com> <87zjbtj6di.fsf@elektro.pacujo.net> NNTP-Posting-Host: c-24-118-110-103.hsd1.mn.comcast.net X-Trace: reader1.panix.com 1416065521 24877 24.118.110.103 (15 Nov 2014 15:32:01 GMT) X-Complaints-To: abuse@panix.com NNTP-Posting-Date: Sat, 15 Nov 2014 15:32:01 +0000 (UTC) User-Agent: slrn/1.0.1 (Linux) Xref: csiph.com comp.lang.python:80826 On 2014-11-15, Marko Rauhamaa wrote: > Tim Chase : > >> And decorators are used pretty regularly in just about every code-base >> that I've touched (I've been programming in Python since early 2004, >> so I've maintained pre-2.4 code without decorators and then brought it >> forward to 2.4 where decorators were usable). > > Funny. My experience with Python is about as old, and I have yet to > encounter them in code. I have seen (maybe even used) @staticmethod once > or twice over a decade and then as a magic keyword rather than a > "decorator pattern." I've been using Python since 1999 and version 1.5.2 and have yet to use decorators. I do occasionally find myself in a spot where I'm pretty sure that there's a more elegent way to do something using a decorator, and promise myself that I'll read up on decorators one of these days when I have some spare time... -- Grant