What is Expressiveness in a Computer Language

Chris Smith cdsmith at twu.net
Mon Jun 19 21:17:15 CEST 2006

Pascal Costanza <pc at p-cos.net> wrote:
> How does your definition exclude the trivial type system in which the 
> only typing judgment states that every expression is acceptable?

It is not necessary to exclude that trivial type system.  Since it is 
useless, no one will implement it.  However, if pressed, I suppose one 
would have to admit that that definition includes a type system that is 
just useless.

I do, though, prefer Pierce's definition:

    A type system is a tractable syntactic method for proving the
    absence of certain program behaviors by classifying phrases
    according to the kinds of values they compute.

(Benjamin Pierce, Types and Programming Languages, MIT Press, pg. 1)

Key words include:

 - tractable: it's not sufficient to just evaluate the program

 - syntactic: types are tied to the kinds of expressions in the language

 - certain program behaviors: while perhaps confusing out of context,
   there is nowhere in the book a specification of which program
   behaviors may be prevented by type systems and which may not.  In
   context, the word "certain" there is meant to make it clear that type
   systems should be able to specifically identify which behaviors they
   prevent, and not that there is some universal set.

Chris Smith - Lead Software Developer / Technical Trainer
MindIQ Corporation

More information about the Python-list mailing list