Search found 23 matches
- Fri Feb 12, 2010 5:48 pm
 - Forum: Common Lisp
 - Topic: How do I know where error is occured?
 - Replies: 5
 - Views: 6552
 
How do I know where error is occured?
Error messages don't always list the function where an error occured.  How do I find this information?
					- Fri Feb 12, 2010 7:48 am
 - Forum: Common Lisp
 - Topic: struct can't be accessed inside loop?
 - Replies: 2
 - Views: 9771
 
Re: struct can't be accessed inside loop?
You're right, and I'm in the wrong section(lisp).  Mods, feel free to move or delete.
					- Fri Feb 12, 2010 7:39 am
 - Forum: Common Lisp
 - Topic: struct can't be accessed inside loop?
 - Replies: 2
 - Views: 9771
 
struct can't be accessed inside loop?
Why am I getting this error from running "contains": "EVAL: undefined function MOVE-X"? (defstruct move state previous f g h) (defun contains (list x) (let ((found nil)) (loop for y in list when (equal (move-x state) (move-y state)) return y))) TEST CODE (setf x (make-move :state...
					- Thu Feb 11, 2010 9:50 am
 - Forum: Common Lisp
 - Topic: " should be a lambda expression" error?
 - Replies: 4
 - Views: 10154
 
- Wed Feb 10, 2010 8:32 pm
 - Forum: Common Lisp
 - Topic: " should be a lambda expression" error?
 - Replies: 4
 - Views: 10154
 
Re: " should be a lambda expression" error?
I found it.  I have one too many parenthesis after do.
The thing is, shouldn't I put the sequence of functions into one s-expression block like let does?
					The thing is, shouldn't I put the sequence of functions into one s-expression block like let does?
- Wed Feb 10, 2010 8:21 pm
 - Forum: Common Lisp
 - Topic: " should be a lambda expression" error?
 - Replies: 4
 - Views: 10154
 
" should be a lambda expression" error?
 (defun manhatten-distance (state) (let ((index 0) (total 0) (current 0) (cvalue 0) (rvalue 0)) (loop for i from 0 to 8 do ((setf current (nth i state)))))) SYSTEM::%EXPAND-FORM: (SETF CURRENT (NTH I STATE)) should be a lambda expression [Condition of type SYSTEM::SIMPLE-SOURCE-PROGRAM-ERROR] Why am...
					- Wed Feb 03, 2010 8:41 pm
 - Forum: Common Lisp
 - Topic: How do I return a list without performing a function on it?
 - Replies: 2
 - Views: 4969
 
Re: How do I return a list without performing a function on it?
Yeah, that fixes it.  I think I was putting my variables in parentheses.
edit: grammar
					edit: grammar
- Wed Feb 03, 2010 8:05 pm
 - Forum: Common Lisp
 - Topic: How do I return a list without performing a function on it?
 - Replies: 2
 - Views: 4969
 
How do I return a list without performing a function on it?
If I want to return a list or nil how do I do that? If I just try to put the name of the list or nil on the last line, lisp tells me it's not a function. I've been using the print function but that isn't going to cut it anymore. For example (defun goalp (state) (let ((x state)) (loop for i from 0 to...
					- Sun Jan 31, 2010 7:43 pm
 - Forum: Common Lisp
 - Topic: Why have the let function when you already have setf?
 - Replies: 16
 - Views: 25050
 
Re: Why have the let function when you already have setf?
Thanks, I think I'm starting to get this functional programming thingamajig.
					- Sun Jan 31, 2010 2:28 pm
 - Forum: Common Lisp
 - Topic: Are ALL S-Expressions really ordered pairs?
 - Replies: 7
 - Views: 9362
 
Re: Are ALL S-Expressions really ordered pairs?
Are functions also considered objects?
Am I to think of these objects as instances of the syntax tree? I'm not sure how this part of the construct works.
					Am I to think of these objects as instances of the syntax tree? I'm not sure how this part of the construct works.