unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Sam Steingold <sds@gnu.org>
To: emacs-devel@gnu.org
Subject: Re: with-standard-io-syntax
Date: Wed, 22 Aug 2012 14:30:23 -0400	[thread overview]
Message-ID: <87y5l6ixts.fsf@gnu.org> (raw)
In-Reply-To: jwvlih6vmwq.fsf-monnier+emacs@gnu.org

> * Stefan Monnier <zbaavre@veb.hzbagerny.pn> [2012-08-22 13:48:43 -0400]:
>
>> The introduction of print-length and print-level requires the CL-like
>> macro with-standard-io-syntax which would bind these (and all the future
>> variables which break read-back consistency) to nil.
>> Right now, (rgrep "print-length nil" "*.el" "~/src/emacs/trunk/" nil)
>> produces two dozen places where print-length is bound to nil and a quick
>> examination shows that the set of variable which need to be bound to nil
>> for print-read consistency is not uniformly understood.
>> I already have been bitten by this, and I think others will be sooner
>> rather than later.
>
> We could/should probably ignore print-length when print-circle is
> non-nil.

This is orthogonal (we can also introduce an all-encompassing
print-readably, but the issue will remain).

There are many variables affecting printing (and more might be added in
the future), and we need a macro which binds them in a way which ensures
read/write consistency, so that package developers do not have to update
their code every time a new variable is introduced.
(http://www.lispworks.com/documentation/HyperSpec/Body/m_w_std_.htm)

The mantra "don't touch these variables and you will be fine" does not
work because some packages (e.g., gnus) bind these vars temporarily and
then the callbacks from them (e.g., bbdb) are screwed wrt read/write
consistency.

-- 
Sam Steingold (http://sds.podval.org/) on Ubuntu 12.04 (precise) X 11.0.11103000
http://www.childpsy.net/ http://ffii.org http://truepeace.org
http://www.memritv.org http://palestinefacts.org http://jihadwatch.org
Our business is run on trust.  We trust you will pay in advance.




  reply	other threads:[~2012-08-22 18:30 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-21 14:36 with-standard-io-syntax Sam Steingold
2012-08-22 17:48 ` with-standard-io-syntax Stefan Monnier
2012-08-22 18:30   ` Sam Steingold [this message]
2012-08-22 19:31     ` with-standard-io-syntax Davis Herring

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

  List information: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to=87y5l6ixts.fsf@gnu.org \
    --to=sds@gnu.org \
    --cc=emacs-devel@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 public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).