all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "Davis Herring" <herring@lanl.gov>
To: "Drew Adams" <drew.adams@oracle.com>
Cc: emacs-pretest-bug@gnu.org
Subject: RE: 23.0.50; savehist save invalid syntax
Date: Mon, 10 Sep 2007 17:55:04 -0700 (PDT)	[thread overview]
Message-ID: <25364.128.165.0.81.1189472104.squirrel@webmail.lanl.gov> (raw)
In-Reply-To: <DHEEKFAFJEFOJHLCFPFDOEOMCAAA.drew.adams@oracle.com>

> The newlines are not necessary, unless you're thinking of someone viewing
> .emacs-history. That is, any whitespace will do. I used a space, but a
> newline is OK too.

If we don't care what the file looks like, lots of things become optional:
(setq foo'bar) works, for instance.  I thought I'd err on the side of
readability.

> In that case, you might want to comment the Lisp code to that effect. It's
> not very obvious that a Lisp reader error could be raised by `prin1'. And
> I
> think it's probably still better to leave the general `error' handler.

I think the documentation for the (new) variable
`print-unreadable-function' may be sufficient, but I could add one.  I
specifically don't want to catch all errors there, because any other error
ought to be noticed, not suppressed.

> What Lisp value can I test for [the new print feature]? It's obviously not
> `emacs-major-version' >= 22. Is there a featurep or fboundp or boundp I
> can test? If not, is there a minor version I can test? If I can't find
> something to test, then I'll have to leave the `read' in for new Emacs
> versions also, which is obviously a waste.

You can, outside the `let', test (boundp 'print-unreadable-function).  You
can also test >= 22.2, if it's added there, or >= 23 otherwise (CVS has
such a version).

> Do as you think best. The doc string suggests that a decimal value is
> used, so I used one. Also, I think decimal is what will be used by most
> users in Customize. That is, even if one can enter #o600 in the Customize
> editable field, I doubt that most users will think to do that. To me, the
> doc string helps in this regard, and a decimal default value helps. I
> don't see a real benefit in using octal here, but that's just my opinion.

Once read, there is no difference between #o600 and 384; there are no
"octal integers", only octal integer literals.  The user never sees it,
then, and it has no effect on Customize.  The doc string is simply
reminding you that the value is the true mode value, and not some
decimal-interpreted-as-octal trick where six hundred sixty means rw-rw----
(and eighty has no meaning at all).

> OK. As I say, I don't recall the specific need. I do recall that it was
> preventing one from quitting Emacs, because `savehist-autosave' is in
> `kill-emacs-hook' (as well as on a timer). That is, if, for any reason, it
> has a problem, then it gets in the way of exiting. That was what was
> happening, but perhaps that problem will never arise in the future ;-).

I wonder why `kill-emacs-hook' is allowed to stop Emacs exiting; if a
function on it signals, shouldn't one just proceed to the next function or
to the actual exit?  It's not supposed to be able to veto exiting; that's
what `kill-emacs-query-functions' is for.

Davis

-- 
This product is sold by volume, not by mass.  If it appears too dense or
too sparse, it is because mass-energy conversion has occurred during
shipping.

  reply	other threads:[~2007-09-11  0:55 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-02 10:38 23.0.50; savehist save invalid syntax Leo
2007-09-02 13:21 ` Drew Adams
2007-09-03  3:04 ` Richard Stallman
2007-09-04 22:48   ` Davis Herring
2007-09-05  3:20     ` Stefan Monnier
2007-09-05  6:16     ` Richard Stallman
2007-09-05 18:16       ` Davis Herring
2007-09-06  5:00         ` Richard Stallman
2007-09-09 21:58         ` Drew Adams
2007-09-09 23:14           ` Andreas Schwab
2007-09-10  3:01             ` Drew Adams
2007-09-10  3:07               ` Drew Adams
2007-09-10 22:11               ` Davis Herring
2007-09-10 23:42                 ` Drew Adams
2007-09-10 23:54               ` Richard Stallman
2007-09-11 20:27                 ` Davis Herring
2007-09-10 21:59           ` Davis Herring
2007-09-10 23:42             ` Drew Adams
2007-09-11  0:55               ` Davis Herring [this message]
2007-09-11  1:11                 ` Stefan Monnier
2007-09-11 21:06                   ` [Released] " Davis Herring
2007-09-11 21:29                     ` Stefan Monnier
2007-09-14  7:04                     ` Richard Stallman
2007-09-11  1:18                 ` Drew Adams
2007-09-05 19:57       ` Leo
2007-10-18 21:08 ` Leo
2007-10-19  8:15   ` Leo
2007-10-19 14:01     ` Stefan Monnier

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=25364.128.165.0.81.1189472104.squirrel@webmail.lanl.gov \
    --to=herring@lanl.gov \
    --cc=drew.adams@oracle.com \
    --cc=emacs-pretest-bug@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.