whoeverest / zozotez

Automatically exported from code.google.com/p/zozotez

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Welcome to Zozotez. Zozotez, which means Lisp in French, is a Lisp interpreter
which runs under any BrainFuck environment.

Zozotez is written in the name of science by Pål Wester to proove that it can
be done in BF and to show off the power EBF provides. Zozotez is not meant to
be a serious interpreter but it could be used to bootstrap serious work since
it is easier creatig a BrainFuck interpreter/compiler than to create a LISP
interpreter. The latest version of Zozotez can be downloaded from
http://sylwester.no/zozotez/ .

BrainFuck is an Esoteric language/turing tarpit that only has enough
instructions to become Turing Complete which means that it is possible to
create any application with it, but not as easy as some other programming
languages. For more information on Brainfuck see
http://en.wikipedia.org/wiki/Brainfuck .

The idea of creating Lisp in Brainfuck started in 2007 when talking with a
collague with my new found fasination and time waster: To create small
brainfuck programs. Later that day we talked about favorite programming
language and he's was Lisp. He said that the language is so easy to implement
that it can be written in BrainFuck. The original LISP was based on research
done by AI researcher John McCarthy in the late 1950's which produced a paper
in 1958 describing the language which also included a interpreter written in
itself using only 9 primitive operators that need to be implemented in some
underlying machinecode. For a breif article on this see
http://www.paulgraham.com/rootsoflisp.html which is slightly easier to
understand than McCarthy's own paper which is more mathematical than
programmer-oriented.

In short, by implementing special forms quote, cond, label and lambda-functions
and normal functions atom, eq, cons, car and cdr you have a turing complete
programming language of a very high level with lots of power. By replacing label
with set (for assigning values or lambda-expressions (functions) to symbols)
you have more power than the first LISP and something usefull. By adding
number support you need add, (additive) inv(erse), and one inequality
operator of <,<=,> or >=.

Zozotez shall not implement the first LISP, but a close decendant. I have no
plans to extend it to conform to either Common Lisp or Scheme, but I guess by
nature it will be closer to Scheme than Common Lisp. It will never be Scheme
since it has dynamic scoping.

How is it possible to create a programming language that can do recursion in a
language that only has while loops? That was the question I asked myself some
years ago and I came to the conclusion that IF you put each 'function' in a
while loop and what function to run in a stack AND do not allow a program to
use lower level code than the provided functions there is no limit other that
memory to how much recursion you may do in BF. Zozotez has been on the drawing
board since I started EBF and it will use lots of EBF-teqniques and data
structures. For design thoughs and documentatiosn other than what provided
in the binary zozotez.bf go to http://sylwester.no/zozotez/

Thank you for you interest in this project :)
Happy hacking
Pål "Sylwester" Wester

About

Automatically exported from code.google.com/p/zozotez

License:GNU General Public License v3.0


Languages

Language:Common Lisp 70.2%Language:Makefile 29.8%