Re: Quoted lambda expressions in manuals

2005-12-17 Thread Luc Teirlinck
Ralf Angeli wrote:

   There are some quoted lambda expressions in the manuals:

   find . -type f -print0 | xargs -0 -e grep -nH -e "'(lambda"
   ./custom.texi:905:  '(lambda ()
   ./custom.texi:1392:  '(lambda ()
   ./custom.texi::  '(lambda () (auto-fill-mode 1)))
   ./emacs-xtra.texi:215: #'(lambda (&optional noconfirm) 'fast))
   ./gnus.texi:3020:  '(lambda nil (local-set-key "d" (local-key-binding "n"

   Maybe those could be removed eventually in order to prevent bad karma
   (as Stefan puts it).

There is a difference between ' and #'.  According to the Elisp
manual, quoting a lambda expression with ' can be used to prevent
byte-compilation.  (If this is incorrect, the Elisp manual should be
corrected.)  Preventing byte-compilation is clearly not intended
in the above examples.

In as far as #' is concerned, `(elisp)Anonymous Functions' points out
that it is no longer really necessary, but goes on to discuss it at
length, and examples in other nodes in the Elisp manual use it.  The
clear impression you get from reading the Elisp doc is that, although
#' (or `function') is not necessary, it is better to use it anyway, as
a sort of comment.  _If_ this is wrong and if the special form
`function' is actually deprecated, then several changes in the Elisp
manual would be needed.  In that case, the discussion of `function' in
`(elisp)Anonymous Functions' should be substantially shortened.  It
should explicitly state that `function' should only be used if you
want your code to work with old Emacs versions.  `function' should not
be used in examples in the Elisp manual.

The main question is:

Is the special form `function' (or #') deprecated or is its use as a
type of comment still encouraged, as the Elisp manual seems to suggest?
Or is it only deprecated for lambda expressions and not for quoting
symbols that are used as functions (where most of the time a simple '
appears to be used in practice anyway)?

Sincerely,

Luc.


___
emacs-pretest-bug mailing list
emacs-pretest-bug@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug


Quoted lambda expressions in manuals

2005-12-14 Thread Ralf Angeli
There are some quoted lambda expressions in the manuals:

find . -type f -print0 | xargs -0 -e grep -nH -e "'(lambda"
./custom.texi:905:  '(lambda ()
./custom.texi:1392:  '(lambda ()
./custom.texi::  '(lambda () (auto-fill-mode 1)))
./emacs-xtra.texi:215: #'(lambda (&optional noconfirm) 'fast))
./gnus.texi:3020:  '(lambda nil (local-set-key "d" (local-key-binding "n"

Maybe those could be removed eventually in order to prevent bad karma
(as Stefan puts it).


In GNU Emacs 22.0.50.1 (i686-pc-linux-gnu, GTK+ Version 2.6.10)
 of 2005-12-14 on neutrino
X server distributor `The X.Org Foundation', version 11.0.60802000
configured using `configure '--with-gtk''

Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: en_US
  locale-coding-system: iso-8859-1
  default-enable-multibyte-characters: t

Major mode: Lisp Interaction

Minor modes in effect:
  desktop-save-mode: t
  display-time-mode: t
  iswitchb-mode: t
  recentf-mode: t
  show-paren-mode: t
  encoded-kbd-mode: t
  auto-compression-mode: t
  mouse-wheel-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  unify-8859-on-encoding-mode: t
  utf-translate-cjk-mode: t
  column-number-mode: t
  line-number-mode: t
  transient-mark-mode: t

Recent input:
M-x r e p o r t - e m  

Recent messages:
Loading time...done
Loading desktop...done
Loading rng-auto (source)...done
Loading /usr/local/share/emacs/site-lisp/tex-site.el (source)...done
Loading easy-mmode...done
Loading edmacro...done
No desktop file.
For information about the GNU Project and its goals, type C-h C-p.
Loading cl-seq...done
Loading emacsbug...done


___
emacs-pretest-bug mailing list
emacs-pretest-bug@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug