Date: February 3, 2009
Location: Linux Caffe
- Abram Hindle
- Telman Yusupov
- Paul Tarvydas
- Vishvajit Singh
This was a general discussion meeting, along with Vish's presentation on the language Factor.
- We need a website, what should be on it
- we should discuss this further
- Factor presentation
- Forth intro
- TELMAN - Read Paper "Out of tarpit"
- Abram goes off about
- Lispy Perl or Perlish Lisp
See attachments on this page for the Factor presentation.
Factor presentation to the Toronto Lisp Users' Group - Tuesday, February 3, 2009
By Vishvajit(Vish) Singh
- Show the basics of FORTH (slide)
- Factor: like FORTH, but modern, compiled, lots of libraries, fun to play with
- Launch Factor, demonstrate use of stack
- push 2, 3, "bob"
- Demonstrate basic operations
- +, *
- Demonstrate stack manipulators
- swap, drop, dup, over, rot
- Demonstrate quotations
- [ 1 + ]
- Demonstrate if
- 2 0 > [ "greater" print ] [ "lesser" print ] if
- demonstrate defining a word for the above operation, check-number
- Demonstrate ctrl-shift-h
- Show the binary tree example (slide)
- Show the code, and demonstrate, the time server example
By Vish Singh
The basic idea of FORTH:
Prefix: f(x, y, z) = + x * y z (defun f (x y z)
(+ x (* y z)))
Infix: f(x, y, z) = x + y * z
Postfix: f(x, y, z) = x y z * +
And in FORTH..
: f * + ;
DEFINE the word f as the concatenation of the two words * and +.
We assume the user has put x, y, and z on the stack before calling f.
The effect of f is to remove x, y, and z, and leave only the result of the computation.