From xemacs-m  Sat May  3 14:41:29 1997
Received: from jagor.srce.hr (hniksic@jagor.srce.hr [161.53.2.130])
	by xemacs.org (8.8.5/8.8.5) with ESMTP id OAA10696
	for <xemacs-beta@xemacs.org>; Sat, 3 May 1997 14:41:28 -0500 (CDT)
Received: (from hniksic@localhost)
          by jagor.srce.hr (8.8.5/8.8.4)
	  id VAA24809; Sat, 3 May 1997 21:41:27 +0200 (MET DST)
To: XEmacs Developers <xemacs-beta@xemacs.org>
Subject: Re: `mapcar' calling SUBRs directly
References: <kigenbomwik.fsf@jagor.srce.hr> <QQcnyy27061.199705031911@crystal.WonderWorks.COM>
X-Save-Project-Gutenberg: <URL:http://www.promo.net/pg/nl/pgny_nov96.html>
X-Attribution: Hrv
X-Face: Mie8:rOV<\c/~z{s.X4A{!?vY7{drJ([U]0O=W/<W*SMo/Mv:58:*_y~ki>xDi&N7XG
        KV^$k0m3Oe/)'e%3=$PCR&3ITUXH,cK>]bci&<qQ>Ff%x_>1`T(+M2Gg/fgndU%k*ft
        [(7._6e0n-V%|%'[c|q:;}td$#INd+;?!-V=c8Pqf}3J
From: Hrvoje Niksic <hniksic@srce.hr>
Date: 03 May 1997 21:41:26 +0200
In-Reply-To: Kyle Jones's message of Sat, 3 May 1997 15:11:18 -0400 (EDT)
Message-ID: <kig207omjh5.fsf@jagor.srce.hr>
Lines: 35
X-Mailer: Gnus v5.4.50/XEmacs 19.15

Kyle Jones <kyle_jones@wonderworks.com> writes:

> Hrvoje Niksic writes:
>  > Here is the patch that avoids using `call1' when `mapcar' is called
>  > with a SUBR (or a symbol whose function is a SUBR) taking exactly one
>  > argument. [...]
> 
> By avoiding the normal Lisp eval path, we lose backtrace
> information and the mapcar loop becomes unquittable.

I don't know about backtrace information, but the mapcar loop is
certainly not made unquittable.  Take this test:

(setq a '(1))
(setcdr a a)           ; a is a circular list

The following is quittable:

(mapc 'ignore a)       ; normal evaluation, as ignore takes optional arugments

But so is the following, at least for me:

(mapc 'identity a)     ; direct evaluation

Note that `mapc' in XEmacs calls `mapc-internal', which in turn calls
`mapcar1' -- so it should demonstrate well.  Besides, I wasn't aware
that quitting a loop depended on functions being called using
`Ffuncall' -- isn't QUIT supposed to be handled by independent IO
routines?

-- 
Hrvoje Niksic <hniksic@srce.hr> | Student at FER Zagreb, Croatia
--------------------------------+--------------------------------
Unspeakable horrors from outer space paralyze the living and
resurrect the dead!

