Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #29490 > unrolled thread
| Started by | Jean-Michel Pichavant <jeanmichel@sequans.com> |
|---|---|
| First post | 2012-09-19 14:47 +0200 |
| Last post | 2012-09-19 14:47 +0200 |
| Articles | 1 — 1 participant |
Back to article view | Back to comp.lang.python
Re: Decorators not worth the effort Jean-Michel Pichavant <jeanmichel@sequans.com> - 2012-09-19 14:47 +0200
| From | Jean-Michel Pichavant <jeanmichel@sequans.com> |
|---|---|
| Date | 2012-09-19 14:47 +0200 |
| Subject | Re: Decorators not worth the effort |
| Message-ID | <mailman.916.1348058864.27098.python-list@python.org> |
----- Original Message ----- > Jean-Michel Pichavant <jeanmichel@sequans.com> writes: > > > ----- Original Message ----- > >> Jean-Michel Pichavant wrote: > > [snip] > >> One minor note, the style of decorator you are using loses the > >> docstring > >> (at least) of the original function. I would add the > >> @functools.wraps(func) > >> decorator inside your decorator. > > > > Is there a way to not loose the function signature as well ? > > Look at the "decorator" module. > Great, thank you. JM
Back to top | Article view | comp.lang.python
csiph-web