Stackd programming language
The Stackd programming language
———— Version 0.1.0 ————–
Stackd is a concatenative programming language, much like Factor and Forth.
It’s somewhat an attempt to write a Factor implementation in Ruby.
In contrast to Factor, Stackd is interpreted and not compiled.
It’s still in an early development phase, so many things aren’t yet supported.
Here’s a small list of features, that currently work already:
- Word definitions
- Most of Factors core words
(still some missing, but shouldn’t be hard to implement)
- Literals for
- Booleans
- Numbers (Integer & Float)
- Strings
- Arrays
- Symbols (as in Ruby)
- Quotations (e.g. first-class ‘functions’)
- Regular Expressions (as in Ruby)
- Hashtables (as in Ruby)
- Booleans
- Two stacks to work with:
- Data stack
(used implicitly and most of the time)
- Retain stack
(used for temporarily storing values with predefined words
e.g.: dip, keep etc.)
- Data stack
- Very lean and simple syntax (as in Factor)
- A simple REPL (see bin/repl)
- Support for debug output via: bin/stackd filename.stackd —debug
–> Outputs the parsed AST
What’s partially implemented:
- A generic object system (as in Factor)
- Support for:
- Generic Words & Methods
- Inheritance
- Generic Words & Methods
What’s still missing (and never might be implemented):
- Private / read-only slots on objects / classes (and probably more)
- Nice development tools, as Factor has them
- Real debugger or walker
- Many more features, you’ll find in Factor
Some basic syntax rules:
- All expressions / statements need to end with a semicolon (‘;’)
- Word definitions start with a colon (‘:’)
- Words can be named almost anything (as in Factor)
e.g.: <>, <a,b>, empty?, >!< etc.
- For more information, have a look at:
http://concatenative.org/
Example code:
* You can find some example code within the examples/ directory.
————– Dependencies ————–
- Treetop for the parser:
http://treetop.rubyforge.org
—————– License ——————
Stackd is licensed under the GNU GPL v3.
It is heavily influenced by the Factor programming language.
Factor is © Slava Pestov. Some parts of Stackd’s core library
is taken from Factor’s.
See http://www.factorcode.org for more information about Factor.
For more information on copying & distribution take a look at the
LICENSE file.
© 2009 Christopher Bertels
http://www.adztec-independent.de
Activities 
-
Monday October 05 2009
-
19:57
Push
-
-
Thursday September 17 2009
-
22:17
Push
-
10:19
Push
-
-
Tuesday September 08 2009
-
17:25
Push
-
17:18
Push
-
09:32
Project
-
09:31
Project
-
09:27
Project
-
-
Monday September 07 2009
-
22:20
Push
-
17:09
Wiki
-
17:09
Push
-
15:41
Wiki
-
15:37
Wiki
-
15:33
Wiki
-
15:30
Wiki
-
-
Sunday September 06 2009
-
01:42
Push
-
01:20
Push
-
-
Saturday September 05 2009
-
13:52
Repository
-
10:00
Push
-
-
Friday September 04 2009
-
14:06
Wiki
-
-
Thursday September 03 2009
-
21:56
Push
-
15:41
Push
-
15:11
Push
-
14:33
Push
-
-
Wednesday September 02 2009
-
23:39
Push
-
23:16
Push
-
20:22
Push
-
10:02
Push
-
00:05
Push
-
-
Tuesday September 01 2009
-
14:43
Project
-


