From xemacs-m  Wed Apr 23 20:51:34 1997
Received: from altair.xemacs.org (steve@xemacs.miranova.com [206.190.83.19])
	by xemacs.org (8.8.5/8.8.5) with ESMTP id UAA18169
	for <xemacs-beta@xemacs.org>; Wed, 23 Apr 1997 20:51:33 -0500 (CDT)
Received: (from steve@localhost)
	by altair.xemacs.org (8.8.5/8.8.5) id TAA14502;
	Wed, 23 Apr 1997 19:04:43 -0700
Mail-Copies-To: never
To: xemacs-beta@xemacs.org
Subject: Re: `purecopy' with lists
References: <kig67xdyioj.fsf@jagor.srce.hr>
X-Url: http://www.miranova.com/%7Esteve/
X-Face: #!T9!#9s-3o8)*uHlX{Ug[xW7E7Wr!*L46-OxqMu\xz23v|R9q}lH?cRS{rCNe^'[`^sr5"
 f8*@r4ipO6Jl!:Ccq<xoV[Qz2u8<8-+Vwf2gzJ44lf_/y9OaQ`@#Q65{U4/TC)i2`~/M&QI$X>p:9I
 OSS'2{-)-4wBnVeg0S\O4Al@)uC[pD|+
X-Attribution: sb
From: Steven L Baur <steve@miranova.com>
In-Reply-To: Hrvoje Niksic's message of 23 Apr 1997 15:26:04 +0200
Mime-Version: 1.0 (generated by tm-edit 7.106)
Content-Type: text/plain; charset=US-ASCII
Date: 23 Apr 1997 19:04:39 -0700
Message-ID: <m2wwptjhvs.fsf@altair.xemacs.org>
Lines: 46
X-Mailer: Gnus v5.4.46/XEmacs 20.2(beta2)

Hrvoje Niksic <hniksic@srce.hr> writes:

> Why (mapcar 'purecopy ...)?  I think that the documentation of
> `purecopy' clearly states that `purecopy' recursively copies lists,
> leaving symbols alone.  Does this suffice:

> (setq completion-ignored-extensions
>       (purecopy
> 	(if (eq system-type 'vax-vms)
> 	       '(".obj" ".elc" ".exe" ".bin" ".lbin" ".sbin"
> 		 ".dvi" ".toc" ".log" ".aux"
> 		 ".lof" ".brn" ".rnt" ".mem" ".lni" ".lis"
> 		 ".olb" ".tlb" ".mlb" ".hlb" ".glo" ".idx" ".lot" ".fmt")
> 	      '(".o" ".elc" "~" ".bin" ".lbin" ".fasl"
> 		".dvi" ".toc" ".log" ".aux" ".a" ".ln"
> 		".lof" ".blg" ".bbl" ".glo" ".idx" ".lot" ".fmt"
> 		".diff" ".oi"))))

I don't think so.  Your version makes a purecopy of everything
including the cons cells, so attempting to modify it is going to
fail.  The original version makes an impure list of pure elements.

I think.  The stuff done with purecopy and allocation in an impure
dumping XEmacs is not very clear.

Hmm, so why can you do:

(setf (car completion-ignored-extensions) ".O")

There is a section about Pure Space in the internals manual:

File: internals.info,  Node: Pure Space,  Next: Cons,  Prev: Low-level allocation,  Up: Allocation of Objects in XEmacs Lisp

Pure Space
==========

   Not yet documented.

:-( :-( :-(

> I ask this because I am preparing a patch to loaddefs.el, so I'd like
> to know the exact usage of `purecopy'.

-- 
steve@miranova.com baur
Unsolicited commercial e-mail will be billed at $250/message.

