Home   lisp   my code

My Lisp code

download (cl-match contains standard-cl)
source files
NEW
cl-match
a fast, expressive pattern-matching library
No unification or backtracking. Supports multiple variable occurances and embedded guards (in embedded OR patterns), expands to efficient runtime code, and has a defmacro-like facility for creating custom patterns.
standard-cl an all-purpose standard library
Lots of random useful stuff, including abbreviations, 2-fix syntax, iterators, math functions, and more. Will eventually be renamed.
2fix

"2-fix" syntax
a lightweight reader macro that swaps the first and second elements of a list in square brackets.

postfix
[list is-empty] => (is-empty list)
[x ^2]          => (^2 x)
infix
[x + y]         => (+ x y)
[x is-in list]  => (is-in x list)
message
passing
[object -> method arg1 arg2] =>
      (-> object method arg1 arg2)
#func partial application
a lightweight reader macro that generates a lambda, where each underline is replaced by a gensym'd argument. Extra trailing arguments can also be indicated by a numerical argument.
#f(push _ xs) => (lambda (#:G1) (push #:G1 xs))
#f[_ + 1]     => (lambda (#:G2) (+ #:G2 1))
#3f(foo) => (lambda (#:G3 #:G4 #:G5) (foo #:G3 #:G4 #:G5))
array-heap a fixed-size heap library based on Introduction to Algorithms by Cormen et. al.
bi-pri a fast, bidirectional priority queue (fixed size, array based). Equivalent to the interval heap.
Othello a simple comand-line game


© 2008 Daniel S. Bensen   Home   About   Site map