Extensible Embeddable Language
   HOME

TheInfoList



OR:

The Extensible Embeddable Language (EEL) is a scripting and programming language in development by David Olofson. EEL is intended for scripting in realtime systems with cycle rates in the kHz range, such as musical synthesizers and industrial control systems, but also aspires to be usable as a
platform independent In computing, cross-platform software (also called multi-platform software, platform-agnostic software, or platform-independent software) is computer software that is designed to work in several computing platforms. Some cross-platform software r ...
general purpose
programming language A programming language is a system of notation for writing computer programs. Most programming languages are text-based formal languages, but they may also be graphical. They are a kind of computer language. The description of a programming ...
.


Philosophy

As to the language design, the general idea is to strike a practical balance between power, ease of use and safety. The intention is to help avoiding many typical programming mistakes without resorting to overly wordy syntax or restricted functionality.


History

The first incarnation of EEL was in the form of a simple parser for structured audio definitions, used in the sound engine of the
Free and Open Source Free and open-source software (FOSS) is a term used to refer to groups of software consisting of both free software and open-source software where anyone is freely licensed to use, copy, study, and change the software in any way, and the source ...
game A game is a structured form of play (activity), play, usually undertaken for enjoyment, entertainment or fun, and sometimes used as an educational tool. Many games are also considered to be work (such as professional players of spectator s ...
Kobo Deluxe, an SDL port of the
X11 The X Window System (X11, or simply X) is a windowing system for bitmap displays, common on Unix-like operating systems. X provides the basic framework for a GUI environment: drawing and moving windows on the display device and interacting wi ...
game XKobo. This was a simple interpreter with very limited flow control, and a syntax that's quite different from that of current versions. This initial branch of EEL was first released in 2002, and is still used in Kobo Deluxe as of version 0.5.1. In December 2003, EEL was split off into a stand-alone project and subject to a major rewrite, in order to be used for real time scripting in an embedded
rheology Rheology (; ) is the study of the flow of matter, primarily in a fluid ( liquid or gas) state, but also as "soft solids" or solids under conditions in which they respond with plastic flow rather than deforming elastically in response to an appl ...
application. This is where the switch from interpreter to
compiler In computing, a compiler is a computer program that translates computer code written in one programming language (the ''source'' language) into another language (the ''target'' language). The name "compiler" is primarily used for programs that ...
/ VM was made, and the actual programming language EEL materialized. The first official release was in January 2005. Since then, EEL has evolved slowly, driven mostly by the personal and professional needs of its author.


Features


General

The language is not strictly designed for any particular
programming paradigm Programming paradigms are a way to classify programming languages based on their features. Languages can be classified into multiple paradigms. Some paradigms are concerned mainly with implications for the execution model of the language, suc ...
, but supports
object oriented programming Object-oriented programming (OOP) is a programming paradigm based on the concept of "objects", which can contain data and code. The data is in the form of fields (often known as attributes or ''properties''), and the code is in the form of pro ...
, or more specifically,
prototype-based programming Prototype-based programming is a style of object-oriented programming in which behaviour reuse (known as inheritance) is performed via a process of reusing existing objects that serve as prototypes. This model can also be known as ''prototypal'' ...
, through a minimal set of syntax sugar features. Other styles and paradigms of programming, such as
functional Functional may refer to: * Movements in architecture: ** Functionalism (architecture) ** Form follows function * Functional group, combination of atoms within molecules * Medical conditions without currently visible organic basis: ** Functional sy ...
,
modular Broadly speaking, modularity is the degree to which a system's components may be separated and recombined, often with the benefit of flexibility and variety in use. The concept of modularity is used primarily to reduce complexity by breaking a sy ...
and
metaprogramming Metaprogramming is a programming technique in which computer programs have the ability to treat other programs as their data. It means that a program can be designed to read, generate, analyze or transform other programs, and even modify itself ...
are also supported. As a result of avoiding
pointers Pointer may refer to: Places * Pointer, Kentucky * Pointers, New Jersey * Pointers Airport, Wasco County, Oregon, United States * The Pointers, a pair of rocks off Antarctica People with the name * Pointer (surname), a surname (including a l ...
and providing fully managed structured data types, EEL is "safe" in the sense that EEL programs should not be able to crash the virtual machine or the host application.


Highlights

* C-like syntax. * Opaque
references Reference is a relationship between objects in which one object designates, or acts as a means by which to connect to or link to, another object. The first object in this relation is said to ''refer to'' the second object. It is called a ''name'' ...
(as opposed to raw
pointers Pointer may refer to: Places * Pointer, Kentucky * Pointers, New Jersey * Pointers Airport, Wasco County, Oregon, United States * The Pointers, a pair of rocks off Antarctica People with the name * Pointer (surname), a surname (including a l ...
). * Dynamic typing. * Automatic memory management. *
Exception handling In computing and computer programming, exception handling is the process of responding to the occurrence of ''exceptions'' – anomalous or exceptional conditions requiring special processing – during the execution of a program. In general, an ...
. * Built-in structured data types, such as: ** ''string'' - immutable
string String or strings may refer to: *String (structure), a long flexible structure made from threads twisted together, which is used to tie, bind, or hang other objects Arts, entertainment, and media Films * ''Strings'' (1991 film), a Canadian anim ...
. ** ''dstring'' - dynamic
string String or strings may refer to: *String (structure), a long flexible structure made from threads twisted together, which is used to tie, bind, or hang other objects Arts, entertainment, and media Films * ''Strings'' (1991 film), a Canadian anim ...
. ** ''vector'' - fixed type numeric
array An array is a systematic arrangement of similar objects, usually in rows and columns. Things called an array include: {{TOC right Music * In twelve-tone and serial composition, the presentation of simultaneous twelve-tone sets such that the ...
. ** ''array'' -
array An array is a systematic arrangement of similar objects, usually in rows and columns. Things called an array include: {{TOC right Music * In twelve-tone and serial composition, the presentation of simultaneous twelve-tone sets such that the ...
of dynamically typed elements. ** ''table'' -
associative array In computer science, an associative array, map, symbol table, or dictionary is an abstract data type that stores a collection of (key, value) pairs, such that each possible key appears at most once in the collection. In mathematical terms an as ...
.


Example code

The classic
hello world program ''Hello'' is a salutation or greeting in the English language. It is first attested in writing from 1826. Early uses ''Hello'', with that spelling, was used in publications in the U.S. as early as the 18 October 1826 edition of the ''Norwich C ...
can be written as follows: export function main The following is an example of a
recursive Recursion (adjective: ''recursive'') occurs when a thing is defined in terms of itself or of its type. Recursion is used in a variety of disciplines ranging from linguistics to logic. The most common application of recursion is in mathematics ...
function: export function main


Internals

EEL source code is compiled into
bytecode Bytecode (also called portable code or p-code) is a form of instruction set designed for efficient execution by a software interpreter. Unlike human-readable source code, bytecodes are compact numeric codes, constants, and references (norma ...
for a custom VM, which has a relatively high level instruction set designed to minimize instruction count and thus overhead. The EEL VM is register based and "stackless", as in not relying on the C
call stack In computer science, a call stack is a stack data structure that stores information about the active subroutines of a computer program. This kind of stack is also known as an execution stack, program stack, control stack, run-time stack, or ma ...
for managing VM contexts. The basic memory management method is reference counting, which allows automatic memory management with deterministic timing, without the need for concurrent garbage collection. The VM uses "limbo lists" to keep track of intermediate objects created inside expressions and the like, which greatly simplifies exception handling, and eliminates the need for active reference counting in every single operation.


Applications


Kobo Deluxe

Kobo Deluxe is an application of EEL.Best of 2013: 31 Years On - Independent Gaming on the Commodore 64
by James Monkman on indiegames.com (December 20, 2013)


References

{{reflist, 30em


External links


EEL homesite

Kobo Deluxe homesite
Scripting languages Free compilers and interpreters Free computer libraries