[Types-sig] Far from Imperfect Summary

Clark C. Evans cce@clarkevans.com
Sun, 18 Mar 2001 21:43:38 -0500 (EST)


http://www.zope.org/Members/michel/types-sig/TreasureTrove

An overall status summary:

  There are two (perhaps three) PEPs being created, with 
  Paul Prescod for a more procedural based approach,
  and Michel Pelletier on a more declarative approach.
  Paul's group has yet to produce a PEP but has a prototype
  implementation, and Michel's group has a PEP posted at:  
  http://www.zope.org/Members/michel/InterfacesPEP/PEP.txt  

Particular Quotes in the last 168 posts I found insightful:

   "The deep(er) part is whether the object passed in thinks of 
    itself as implementing the Foo interface. This means that
    its author has (presumably) spent at least a little time 
    about the invariants that a Foo should obey." -- Guido

    "Type errors are not even close to the majority of those 
     I make while programming in Python... Expressiveness, 
     IMO, is a far better aid to correctness than artificial 
     restrictions" -- Uche

    "1. Better error checking (major), 
     2. Better documentation (major),
     3. Optimization (minor), 
     4. Static Type Glue (minor). 
     For now drop static type checking and higher order types. 
     If Python's type system makes anyone's brain explode then 
     we have not done a good job." -- Prescod on Goals

    "This suggestion provides a powerful (Turing-complete!) 
     way of defining types." -- Prescod on Tim Hochberg's proposal

    "In short, it looks like we will need to agree on the Python 
     type hierarchy before we can ever hope to agree on any kind 
     of type assertions." -- Guido

    "We can write code quickly in Python in part because we 
     don't have to decide in advance which methods we want to 
     require -- and we don't have to implement every method 
     that a builtin file has when we write a class that is a 
     file-like object." -- Jeremy Hylton 

    "Type Inference will never work well in Python. Python is 
     too dynamic and the behavior of libraries wrt. types is 
     too irregular to be inferred statically from usage (perhaps 
     except most simple cases, which is impractical)." and
     -- Marcin 'Qrczak' Kowalczyk

    "Collections are where typechecking is most needed, and where 
     it is least provided." -- Krishnaswami, Neel 

    "There is no concept of asking an object which interface it
     implements. There is no "the" interface it implements. It's
     not even a set of interfaces, because the object doesn't 
     know them in advance. Interfaces can be defined after objects
     conforming to them are created." -- Marcin 'Qrczak' Kowalczyk