unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: emacs-devel@gnu.org
Subject: Re: push and pop
Date: Fri, 07 Jan 2005 15:23:38 -0500	[thread overview]
Message-ID: <jwvk6qphtxd.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <pan.2005.01.07.18.21.53.124866@as.arizona.edu> (JD Smith's message of "Fri, 07 Jan 2005 11:21:53 -0700")

> The macros "push" and "pop" in `subr' don't do the same thing as the push
> and pop in `cl'.  This means that if you use:

>  (eval-when-compile (require 'cl))

> in your code, the behavior will change depending on whether the compiled
> version is loaded (cl version), or you are interactively debugging (subr
> version).  An example of a semantic which will fail with the subr version
> but not the cl version:

>  (setq ov (pop (cdr ov-list)))

> which requires a list argument to pop, instead of the cdr of a list.

I don't see the problem.  When debugging code in a file that does (require
FOO), you need to (require FOO) before doing C-x C-e or M-C-x.
Nothing new here.

The only difference is that in macs-20 (when subr.el didn't define its iown
version of `pop') you'd get an error "void function `pop'" whereas now you
get another error.

> Any suggestions on how to work around this (other than the obvious "don't
> do that")?

Don't do that,


        Stefan

  parent reply	other threads:[~2005-01-07 20:23 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-01-07 18:21 push and pop JD Smith
2005-01-07 19:39 ` David Kastrup
2005-01-07 20:23 ` Stefan Monnier [this message]
2005-01-07 21:15   ` JD Smith
2005-01-08  2:19     ` Miles Bader
2005-01-08 15:34     ` Richard Stallman
2005-01-09 17:53       ` JD Smith
2005-01-09 19:04         ` Francis Litterio
2005-01-09 19:42         ` Luc Teirlinck
2005-01-09 19:56           ` David Kastrup
2005-01-10 20:27             ` Richard Stallman

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=jwvk6qphtxd.fsf-monnier+emacs@gnu.org \
    --to=monnier@iro.umontreal.ca \
    --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).