[Ecls-list] Command-line argument weirdness

Dustin Long dlong at progmatism.com
Fri May 16 16:37:37 UTC 2008

For your first question, get rid of the backslash.

ecl -eval "(require 'asdf)"

should work just fine. When you use the backslash, the quote is treated as
just another character in the symbol name.

For your second question, the asdf:: package prefix is handled at read time,
whereas the require form is evaluated after the entire progn form has been
read and compiled. So the asdf package is being looked for before it is
loaded. You can work around this like so:

ecl -eval "(progn (require 'asdf) (eval (read-from-string \"(asdf ...)\")))"

On Fri, May 16, 2008 at 11:33 AM, Mark Hoemmen <mark.hoemmen at gmail.com>

> Just wondering -- how come
> ecl -eval "(require \'asdf)"
> breaks with the message:
> An error occurred during initialization:
> The variable |'ASDF| is unbound..
> but
> ecl -eval "(require :asdf)"
> works just as if I had typed either "(require :asdf)" or "(require
> 'asdf)" at the prompt?
> Also,
> ecl -eval "(progn (require :asdf) (push (truename \".\")
> asdf:*central-registry*))"
> gives me the error
> An error occurred during initialization:
> There is no package with the name ASDF..
> Not a big deal since I can get the same effect by stuffing these
> commands into a file and using the -shell option, but it's still kind
> of weird.  I'm not sure why text from the command line would be
> handled differently than text from the prompt.
> mfh
> -------------------------------------------------------------------------
> This SF.net email is sponsored by: Microsoft
> Defy all challenges. Microsoft(R) Visual Studio 2008.
> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
> _______________________________________________
> Ecls-list mailing list
> Ecls-list at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/ecls-list
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.common-lisp.net/pipermail/ecl-devel/attachments/20080516/86c1a342/attachment.html>

More information about the ecl-devel mailing list