[Python-3000] Adaptation and type declarations
Josiah Carlson
jcarlson at uci.edu
Tue Apr 11 01:58:28 CEST 2006
"Chaz." <eprparadocs at gmail.com> wrote:
> Is that what adding some typing to the system will do?
Not necessarily, but this particular instance isn't necessarily a
typing-system issue. All sane or insane implementations of the @throws
decorator that I can think of (annotation, exception translation,
unittest, etc.) offer no improvement to the language that would warrant
the necessity of a "throws" syntax to replace the @throws decorator.
Remember, not all X line functions should become builtins or syntax.
- Josiah
> Josiah Carlson wrote:
> > "Chaz." <eprparadocs at gmail.com> wrote:
> >> If you are going this far, why not also support a throws() modifier (or
> >> whatever you might call it).
> >>
> >> Right now I do something like:
> >>
> >> @throws(IOError)
> >> def foo(...) :
> > ...
> >> I might suggest
> >>
> >> def foo(...) throws(...) :
> >>
> >> as a more integrated approach.
> >
> > You are just relocating decorators. Stop.
> >
> >
> > - Josiah
> >
> >
More information about the Python-3000
mailing list