EuLisp is a statically and dynamically
scoped Lisp
Lisp (historically LISP, an abbreviation of "list processing") is a family of programming languages with a long history and a distinctive, fully parenthesized Polish notation#Explanation, prefix notation.
Originally specified in the late 1950s, ...
dialect developed by a loose formation of industrial and academic Lisp users and developers from around Europe. The
standardizers intended to create a new
Lisp
Lisp (historically LISP, an abbreviation of "list processing") is a family of programming languages with a long history and a distinctive, fully parenthesized Polish notation#Explanation, prefix notation.
Originally specified in the late 1950s, ...
"less encumbered by the past" (compared to
Common Lisp
Common Lisp (CL) is a dialect of the Lisp programming language, published in American National Standards Institute (ANSI) standard document ''ANSI INCITS 226-1994 (S2018)'' (formerly ''X3.226-1994 (R1999)''). The Common Lisp HyperSpec, a hyperli ...
), and not so
minimalist as
Scheme. Another objective was to integrate the
object-oriented programming
Object-oriented programming (OOP) is a programming paradigm based on the concept of '' objects''. Objects can contain data (called fields, attributes or properties) and have actions they can perform (called procedures or methods and impl ...
paradigm well. It is a
third-generation programming language
A third-generation programming language (3GL) is a high-level programming language, high-level computer programming language that tends to be more machine-independent and programmer-friendly than the machine code of the First-generation programmin ...
.
Origin
The language definition process first began in a meeting in 1985 in
Paris
Paris () is the Capital city, capital and List of communes in France with over 20,000 inhabitants, largest city of France. With an estimated population of 2,048,472 residents in January 2025 in an area of more than , Paris is the List of ci ...
and took several years. The complete specification and a first implementation (
interpreted-only) were made available in 1990.
Distinguishing features
Its main traits are that it is a Lisp-1 (no separate function and variable namespaces), has a ''
Common Lisp Object System'' (CLOS) style generic-function type object-oriented system named ''The EuLisp Object System'' (TELOS) integrated from the ground up, has a built-in module system, and is defined in layers to promote the use of the Lisp on small, embedded hardware and educational machines. It supports
continuation
In computer science, a continuation is an abstract representation of the control state of a computer program. A continuation implements ( reifies) the program control state, i.e. the continuation is a data structure that represents the computat ...
s, though not as powerfully as
Scheme. It has a simple lightweight process mechanism (
threads).
Summary
* A definition in levels, currently Level-0 and Level-1
* Modules based on (non-
first-class)
lexical environments.
*
Lexically scoped
In computer programming, the scope of a name binding (an association of a name to an entity, such as a variable) is the part of a program where the name binding is valid; that is, where the name can be used to refer to the entity. In other parts ...
, with dynamic or
late binding available in Level-1.
* A single name space for function and variable names (like
Scheme).
* Lightweight processes.
* A fully integrated
object system with
single inheritance at Level-0 and
multiple inheritance
Multiple inheritance is a feature of some object-oriented computer programming languages in which an object or class can inherit features from more than one parent object or parent class. It is distinct from single inheritance, where an object ...
and
meta-object protocol at Level-1.
* An
object-oriented
Object-oriented programming (OOP) is a programming paradigm based on the concept of '' objects''. Objects can contain data (called fields, attributes or properties) and have actions they can perform (called procedures or methods and impleme ...
condition system.
Implementations
An early implementation of EuLisp was ''Free and Eventually Eulisp'' (FEEL). The successor to FEEL was ''Youtoo'' (interpreted and
compiled versions), by
University of Bath
The University of Bath is a public research university in Bath, England. Bath received its royal charter in 1966 as Bath University of Technology, along with a number of other institutions following the Robbins Report. Like the University ...
in the
United Kingdom
The United Kingdom of Great Britain and Northern Ireland, commonly known as the United Kingdom (UK) or Britain, is a country in Northwestern Europe, off the coast of European mainland, the continental mainland. It comprises England, Scotlan ...
.
An interpreter for the basic level of EuLisp, ''level-0'', was written by Russell Bradford in XScheme, an implementation of
Scheme by David Michael Betz, originally named EuSchem
EuSchemebut the most recent version is renamed EuXLis
to avoid confusion. Also Eu2
a EuLisp optimizing compiler, was created by Fraunhofer ISST under the APPLY project in German
A dialect of EuLisp was developed, named Plural EuLisp. It was EuLisp with
parallel computing
Parallel computing is a type of computing, computation in which many calculations or Process (computing), processes are carried out simultaneously. Large problems can often be divided into smaller ones, which can then be solved at the same time. ...
programming extensions.
Example
Example use of classes in the algorithm to solve the "
Towers of Hanoi" problem.
(defmodule hanoi
(syntax (syntax-0)
import (level-0)
export (hanoi))
;;;-------------------------------------------------
;;; Tower definition
;;;-------------------------------------------------
(defconstant *max-tower-height* 10)
(defclass ()
((id reader: tower-id keyword: id:)
(blocks accessor: tower-blocks)))
(defun build-tower (x n)
(labels ((loop (i res)
(if (= i 0) res
(loop (- i 1) (cons i res)))))
((setter tower-blocks) x (loop n ()))
x))
(defmethod generic-print ((x ) (s ))
(sformat s "#" (tower-id x) (tower-blocks x)))
;;;-------------------------------------------------
;;; Access to tower blocks
;;;-------------------------------------------------
(defgeneric push (x y))
(defmethod push ((x ) (y ))
(let ((blocks (tower-blocks x)))
(if (or (null? blocks) (< y (car blocks)))
((setter tower-blocks) x (cons y blocks))
(error
(fmt "cannot push block of size ~a on tower ~a" y x)))))
(defgeneric pop (x))
(defmethod pop ((x ))
(let ((blocks (tower-blocks x)))
(if blocks
(progn
((setter tower-blocks) x (cdr blocks))
(car blocks))
(error
(fmt "cannot pop block from empty tower ~a" x)))))
;;;-------------------------------------------------
;;; Move n blocks from tower x1 to tower x2 using x3 as buffer
;;;-------------------------------------------------
(defgeneric move (n x1 x2 x3))
(defmethod move ((n ) (x1 ) (x2 ) (x3 ))
(if (= n 1)
(progn
(push x2 (pop x1))
(print x1 nl x2 nl x3 nl nl))
(progn
(move (- n 1) x1 x3 x2)
(move 1 x1 x2 x3)
(move (- n 1) x3 x2 x1))))
;;;-------------------------------------------------
;;; Initialize and run the 'Towers of Hanoi'
;;;-------------------------------------------------
(defun hanoi ()
(let ((x1 (make id: 0))
(x2 (make id: 1))
(x3 (make id: 2)))
(build-tower x1 *max-tower-height*)
(build-tower x2 0)
(build-tower x3 0)
(print x1 nl x2 nl x3 nl nl)
(move *max-tower-height* x1 x2 x3)))
(hanoi)
;;;-------------------------------------------------
) ;; End of module hanoi
;;;-------------------------------------------------
References
"An Overview of EuLisp" Julian Padget, Greg Nuyens, and Harry Bretthauer, editors. ''LISP and Symbolic Computation'', Volume 6, Number 1-2, 1993, pages 9–98.
"Balancing the EuLisp Metaobject Protocol" Harry Bretthauer, Jürgen Kopp, Harley Davis, and Keith Playford. ''LISP and Symbolic Computation'', Volume 6, Issue 1–2, August 1993, pages 119–138.
"EuLisp in Education" R. Bradford and D.C. DeRoure. ''LISP and Symbolic Computation'', Volume 6, Number 1-2, pages 99–118.
"Applications of Telos" Peter Broadbery, Christopher Burdorf. ''LISP and Symbolic Computation'', Volume 6, Issue 1–2, August 1993, pages 139–158.
"A Practical Approach to Type Inference for EuLisp" Andreas Kind and Horst Friedrich. ''LISP and Symbolic Computation'', Volume 6, Issue 1–2, August 1993, pages 159–176.
"EuLisp Threads: A Concurrency Toolbox" Neil Berrington, Peter Broadbery, David DeRoure, and Julian Padget. ''LISP and Symbolic Computation'', Volume 6, Issue 1–2, August 1993, pages 177–200.
"Plural EuLisp: A Primitive Symbolic Data Parallel Model" Simon Merrall, Julian Padget. ''LISP and Symbolic Computation'', Volume 6, Issue 1–2, August 1993, pages 201–219.
"A Conservative Garbage Collector for an EuLisp to ASM/C Compiler" E. Ulrich Kriegel. ''OOPSLA'93 Workshop on Garbage Collection and Memory Management'', Washington, DC, September 27, 1993.
"An Implementation of Telos in Common Lisp", ''Object Oriented Systems'', vol. 3, pp. 31–49, 1996. ISSN 0969-9767.
External links
Version .99of the final 1993 specification – (
PDF
Portable document format (PDF), standardized as ISO 32000, is a file format developed by Adobe Inc., Adobe in 1992 to present documents, including text formatting and images, in a manner independent of application software, computer hardware, ...
)
Version .991 unofficial updated draft definition (2010) – (
PDF
Portable document format (PDF), standardized as ISO 32000, is a file format developed by Adobe Inc., Adobe in 1992 to present documents, including text formatting and images, in a manner independent of application software, computer hardware, ...
)
EuSchemesources
* , latest versions of: EuLisp (with 64-bit support and more), EuXLisp, Eu2C
{{Lisp programming language
Dynamically typed programming languages
Functional languages
Lisp programming language family
Multi-paradigm programming languages