Skip to content

Instantly share code, notes, and snippets.

@ELLIOTTCABLE
Forked from atg/gist:264032
Created December 26, 2009 20:31
Show Gist options
  • Save ELLIOTTCABLE/264034 to your computer and use it in GitHub Desktop.
Save ELLIOTTCABLE/264034 to your computer and use it in GitHub Desktop.
foo = routine
lookup = routine
# All lookups after foo are put into @
# so 'foo bar baz' would give you @ = (bar baz)
out = @0
# The default implementation does a reduce() with dereferencing, something like this
@.prepend(this)
reduce(@0)
@2(@0[@1])
out(@0)
foo bar baz # will call our lookup with `foo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment