Re: [patch] sawfish.wm.util.prompt
- From: Timo Korvola <Timo Korvola iki fi>
- To: sawfish-list gnome org
- Subject: Re: [patch] sawfish.wm.util.prompt
- Date: Sat, 19 Sep 2009 18:59:28 +0300
On Monday 07 September 2009 20:30:39 Matthew Love wrote:
> So as far as the compiler was concerned, the functions, defvar'd to
> nil, did not take any arguments.
The original code looks fine to me. It seems that the compiler is
broken here, fortunately only by emitting spurious warnings rather than
producing broken byte code. The compiler should have figured out that
because the called variable is a defvar, it is likely to be changed, and
because it is nil, it has to be changed before the function call occurs.
Hence it is difficult or impossible to analyse statically.
> Re-defining the intital defvar's from nil to (lambda (#!rest) nil)
That is actually a syntax error, although presently undetected by rep.
#!rest should be followed by a parameter name, e.g., (lambda (#!rest
foo) nil) or in Scheme style (lambda foo nil).
Note that the general direction in Sawfish has been towards Scheme
style. New code should use define rather than defun.
--
Timo Korvola <URL:http://www.iki.fi/tkorvola>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]