to see in what directory ASDF starts looking. You can also specify this yourself, using the interface edgar-rft linked to, but that's quite a bit of a clusterfoo.
Hi, Can we define global variable in lisp !? If we have it in lisp, how we can define it ? (defvar foo 3) Creates a global variable and assings it the value 3. (defvar foo 3 "This is foo, which should be 3") Does the same, but associates a docstring to it, which will be shown if you (insp...
Macros run (are expanded) at compile-time. Functions run at run-time. Hence, functions cannot call macros. A macro form can appear in a function's body, of course. But the same principle applies: The macro is expanded during compilation, not when the function is called. Assuming you have the follow...
SBCL or CCL are probably fast enough to handle the non time-critical parts of a game (or everything, if you're willing to settle for something that looks like it's from 2008). If I'd be doing an advanced game in Lisp, I'd probably write the critical parts as functions in C or ASM and call those from...
I can not understand this line of code : (defun loop?_0 (x) (eql x 4)) "?" is a part of the function's name ? or something else !? Lisp allows you to use all ascii-characters (IIRC, could be printable ascii characters) or unicode characters, depending on the native character set of your i...
The problem isn't scoping, it's that your backquoting levels aren't in order. The inner defmacro is inside a single backquote, so the call to ,@body is going to look for body outside of that backquote level and it finds a symbol, not a list (because that's what you introduced with intern). But the c...
Easiest way would be to let Lisp copy the list for you (say hi to copy-tree) and destructively alter the new list (technically a tree since it can contain sublists, hence the use of copy-tree as opposed to copy-list). |Then just check if the final argument is a cons or a number and handle each case ...
Or if you prefer loops you could also use: (The proposed recursive version should be tail-recursive, but if you're unlucky with your compiler/interpreter it may blow the stack for very large lists) (defun sublist-p (list) (loop for el in list for sublist-p = (consp el) do (when sublist-p (return t))...
The behavior is the same under CCL 1.6 (the version I posted) and the version of SBCL I have (0.9.8.1? Most recent stable windows build as of June, IIRC). However, Ramarren seems to have nailed it, I need to load libfreetype-6.dll before loading sdl-ttf.dll. Now I just need to figure out in what ord...