X-Git-Url: https://code.consxy.com/gitweb/gitweb.cgi?p=clnl;a=blobdiff_plain;f=src%2Fmain%2Flex.lisp;h=d39ab5922e1545134b3eaaa262c41179b0eb4cc2;hp=b0ef2f1d1a591c8b6940093e09c83e52120fcdc5;hb=5c8699f151207953f4029e0fc6c488afce99f756;hpb=471de83db1aee70065808cbc061867e3320bf4b7 diff --git a/src/main/lex.lisp b/src/main/lex.lisp index b0ef2f1..d39ab59 100644 --- a/src/main/lex.lisp +++ b/src/main/lex.lisp @@ -32,6 +32,20 @@ *lexes*)))) (defun lex (text) + "LEX TEXT => AST + +ARGUMENTS AND VALUES: + + TEXT: Some NetLogo code + AST: An ambigious AST that can later be parsed + +DESCRIPTION: + + LEX lexes NetLogo code. + + LEX checks for some things, in as much as it can without knowing anything + about some of the backgrounds of NetLogo. However, it does the first pass + with as much as it can." (if (string= "" text) (let ((lex (find-if (lambda (f) (funcall f *state* :eof)) *lexes* :from-end t :key #'car)))