Typed Python?

Paul Prescod paul at prescod.net
Sun Jul 4 09:26:07 CEST 2004

Ville Vainio wrote:

>>>>>>"Jarek" == Jarek Zgoda <jzgoda at gazeta.usun.pl> writes:
>     Jarek> Static typing would destroy all fun in Python. Eventually
>     Jarek> we would end with ObjectPascal-like language, just running
>     Jarek> in VM and not compiled.
> Using a type inference system, it wouldn't. The code would "flow" like
> it does now. Some corners of the code would probably benefit from
> having explicit declarations to smooth up the process, but most of the
> code could look exactly the way it does now.

I don't really believe that is true. Many Python functions have 
extremely complex type signatures. In a type inferenced language you 
don't type in type signatures everywhere but you do define have to 
design your types with the inferencer in mind. This would be a big 
change in Python programming style.

To put it another way: Jarek complains that static typing would destroy 
the "fun". I think he means Python's flexibility. A type inferencer 
removes the need to declare types but a statically type-inferenced 
language is still statically typed. It will still be strict about type 

  Paul Prescod

More information about the Python-list mailing list