I just started using LISP, coming from a background in C. So far its been fun, although with an incredible learning curve (I'm an emacs newbie too).
Anyway, I'm having a silly issue with the following code to parse include statements from c source - if anyone can comment on this and suggest a solution, it would help a lot.
(defun include-start ( line )
(search "#include " line))
(defun get-include( line )
(let ((s (include-start line)))
(if (not (eq NIL s))
(subseq line s (length line)))))
(get-include "#include <stdio.h>")
I expect the last line to return
"<stdio.h>"
However the actual result is
"#include <stdio.h>"
Any thoughts?