Hi,
If you are looking for an embeddable byte-code compiled/interpreted
language which is useful as both an extension and a command language which
syntax is designed to be easy to learn and to be fairly good looking then
the best I have found ( expecially for dumb users ) is IVY (version 2).
Ivy currently supports four data types: integers, strings, functions and
objects. Objects are late-binding storage devices which take the role of
arrays, structures and simple look-up tables. Floating point or arbitrary
length floating point numbers will be available in a future
implementation. Ivy comes packaged as an interactive language like BASIC
and LISP. You can either execute language statements immediately from the
keyboard or run a program stored in a file. Ivy is also easy to embed
into another program. Calls are provided to execute Ivy code and to add C
function extensions to Ivy's interpreter.
have a look at this ( sort.i ) :
---------------------------------------------------------------------------
# Bubble sort function
:sort array
loop # Loop until sorted
flg=0
for a=0, a!=len[array]-1, ++a # Check array
if array[a]>array[a+1] # Element out of order?
array[a]=array[a+1]:array[a] # Swap it...
flg=1
until !flg
return array
# Example uses
print sort[{3 8 2 6 4 5 1 9}]
print sort[{"this" "is" "a" "test" "of" "this" "thing"}]
---------------------------------------------------------------------------
Adding C ( compiled ) functions to it is very simple. You can even have an
"overloaded" function which accepts different types of arguments ( inside
of the function body you can check the type of the actual parameter ).
I have here complete sources ( I don't remember now where I have found
original sources - but I had problems compiling them on some stupid OS, so
my sources are cleaned ). The .zip file is 30kB long, the unziped source
code is some 60kB long. Let me know if you are interested and I'll send it
to you.
Jacek.