[plt-scheme] Smallest set of operators
On Feb 2, 2007, at 8:28 AM, Paulo J. Matos wrote:
> Ok,
> I think we got to a lot more theoretical discussion than I initially
> intended. This is just mere curiosity and not directly involving my
> work, although somewhat related. What happened was I was thinking to
> myself: "Guess I would like to write a compiler for Scheme in C (or
> some other language other than Scheme iteself) and that I would want
> to spare the trouble of writing C. So I would write the bare minimum
> in C, the rest in Scheme using the C layer. Now, what would I have to
> write in the C layer? In other words, what would I need initially in
> the Scheme layer to implement the rest of scheme. No matter efficiency
> issues... Maybe I could have initially define, lambda, null?, '(),
> car, cons, cdr. Would I need anything else? Would you need anything
> else? Could you find a set with less than 7 operators (see operator
> here in a wider sense since '() is not really an operator)?
You're still being way too vague. Depending on what you want, the
answers might include any of the following:
1) just the C primitives. Then your upper layer needs to compile to C.
2) Some kind of assembly language
3) A tree-based language of combinators (cf earlier discussion of X)
4) something like Kelsey (& Rees's?) pre-scheme.
5) the lambda calculus.
...
It depends entirely on what your goals are. The question as you've
stated it does not have anything like a single answer.
John Clements
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 2484 bytes
Desc: not available
URL: <http://lists.racket-lang.org/users/archive/attachments/20070202/4e639bfd/attachment.p7s>