[Python-3000] Conventions for annotation consumers (was: Re: Draft pre-PEP: function annotations)

Collin Winter collinw at gmail.com
Tue Aug 15 21:13:16 CEST 2006

On 8/15/06, Paul Prescod <paul at prescod.net> wrote:
> A Typechecking consumer and a PyPy compiler consumer might work on the same
> annotations because they are both interested in TYPES (but doing different
> things with them). These type consumers might also choose to implement more
> than one type checking syntax, if there were a good reason that more than
> one arose (perhaps Unix types versus .NET types).
> A docstring consumer and a typechecking consumer would *by definition* use
> different syntaxes/frameworks/wrappers because the information that they are
> looking for is different! But there could be hundreds of docstring consumers
> (as there are today!). Docstrings are a special case because the syntax for
> them is fairly obvious (an unadorned string).

So basically what you're saying is that there would be a more-or-less
standard wrapper for each application of function annotations. How is
this significantly better than my dict-based approach, which uses
standardised dict keys to indicate the kind of metadata?

Collin Winter

More information about the Python-3000 mailing list