Subject: Use of .lisp Extension

From: Ray Liere <[email-masked]>
Date: Tue, 10 Jan 1995 20:50:50 -0800

I am using some provided Lisp source code as a starting point for
a project, and all of the sources are named with the ".lisp" extension
instead of the ".lsp" that clisp expects. Does anyone know of a relatively
easy way to have clisp recognize ".lisp" as well as ".lsp" as legal?
(I am currently using the method of simply renaming all of the sources,
but would like to avoid that in the future if possible).

Thanks.
Ray Liere
[email-masked]

---

From: [email-masked] (Richard Shepherd)
Date: Thu, 12 Jan 95 12:30 NZDT

> From: Ray Liere <[email-masked]>
> 

I can't find any variable that contains the value of the expected
extension if none is given so I assume it is built in at compile time
to clisp.

An easy way to overcome this to me seems to be something like the
following:

(defun myload (file &key (extension "lisp"))
  (load (concatenate 'string file "." extension)))

then instead of going

(load file)

go

(myload file)

and you only need specify the extension when it's not .lisp.
Something a little more elaborate might be better if you want it fall
back on .lsp when there's no .lisp found, but I'm sure you can figure
that out ;-)

I hope that helps,

8<--------------------------->8

Richard Shepherd. 

([email-masked])