[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gcl-devel] Re: Error when compiling function with doc string, declarati
From: |
Camm Maguire |
Subject: |
[Gcl-devel] Re: Error when compiling function with doc string, declaration |
Date: |
15 Mar 2006 14:13:09 -0500 |
User-agent: |
Gnus/5.09 (Gnus v5.9.0) Emacs/21.2 |
Greetings! This should be fixed now on branch 2.6.8pre and cvs head.
Please let me know if problems persist.
Take care,
Jared Davis <address@hidden> writes:
> Hi Camm,
>
> I am running GCL 2.6.7 CLtL1, installed via apt-get on ubuntu. If I write:
>
> (defun foo (x)
> "baz"
> (declare (type integer x))
> x))
>
> Then this is accepted, and everything seems fine. For example, I can
> write (documentation 'foo 'function) and "baz" is returned; similarly
> I can run (foo 3) and obtain 3 as expected. But if I try to compile
> foo, I get an error message:
>
>
> Compiling gazonk6.lsp.
> ; (DEFUN FOO ...) is being compiled.
> ;;; The declaration (DECLARE (TYPE INTEGER X)) was found in a bad place.
> No FASL generated.
>
> Error: Cannot open the file NIL..
> Fast links are on: do (si::use-fast-links nil) for debugging
> Error signalled by LET.
> Broken at LOAD. Type :H for Help.
>
>
> If I switch the order of the declaration and the documentation string,
> the problem goes away.
>
> Maybe this is a bug. But, looking at the grammar for "defun" on the
> Common Lisp Hyperspec, it seems like providing both documentation and
> declarations is actually not allowed. How bizarre! Could this really
> be intentional?
>
> For what it's worth, this error does not seem to occur on GCL 2.6.6,
> but does occur on 2.7.0 ANSI.
>
> Thanks,
>
> Jared
>
>
--
Camm Maguire address@hidden
==========================================================================
"The earth is but one country, and mankind its citizens." -- Baha'u'llah