[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Jonathan Rees on OO

Paul, you don't have to go to bunches of bytes and do things atop. 

In PLT Scheme v200 everything is a struct, yet these values won't respond
with #t to struct? because we don't want anyone to think of these things as

Also, we are currently designing extensions so that programmers can define
functions and ask the environment to treat them as primitives, especially
with respect to soft typing. So you will  say something like 

 (: f (number -> number))
 (define (f x) ... (+ x ...) ...)

and f is treated as a new "primitive". If the soft typer sees that you
misapply it somewhere, it will be hi-lited in red. It's up to you to think
of this as a typer and you will refrain from running this code, or you may
decide that the type system is too conservative and you run the code
anyway, knowing that we enforce the types anyway. 

The key is not just to write the types down. You need to analyze and
enforce them. And in "Lisp" (or Perl or Python or Curl) the question is how
to scale this to higher-order types. 

Even more general: we have known fro 50 years how to build a language atop
bunches of bytes. PL design will make progress if we do the exact same
thing but without ever thinking what is inside the machine. Computations
are about value manipulations. At the moment, we represent values in bits
and bytes, but why think about those. It just pollutes program design. 

-- Matthias