From xemacs-m  Sun Feb  9 18:04:39 1997
Received: from wmperry.in.aventail.com (wmperry@wmperry.oz.net [207.13.185.53])
	by xemacs.org (8.8.5/8.8.5) with ESMTP id SAA19253
	for <xemacs-beta@xemacs.org>; Sun, 9 Feb 1997 18:04:27 -0600 (CST)
Received: (from wmperry@localhost) by wmperry.in.aventail.com (8.7.6/8.7.3) id QAA01353; Sun, 9 Feb 1997 16:09:40 -0800
Date: Sun, 9 Feb 1997 16:09:40 -0800
Message-Id: <199702100009.QAA01353@wmperry.in.aventail.com>
From: "William M. Perry" <wmperry@aventail.com>
To: xemacs-beta@xemacs.org
Subject: Bogus text-property lossage
Errors-to: wmperry@aventail.com
Reply-to: wmperry@aventail.com
X-Face: O~Rn;(l][/-o1sALg4A@xpE:9-"'IR[%;,,!m7</SYF`{vYQ(&RI1&EiH[FvT;J}@f!4kfz
 x_!Y#=y{Uuj9GvUi=cPuajQ(Z42R[wE@{G,sn$qGr5g/wnb*"*ktI+,CD}1Z'wxrM2ag-r0p5I6\nA
 [WJopW_J.WY;

With Emacs-W3, I use text properties, just for sanities sake for XEmacs &
Emacs.  These get cut and pasted a lot when doing tables.  I've recently
been getting bitten by the following traceback quite a bit:

Signaling: (error "internal error: no text-prop" #<extent [0, 5) D paste-function text-prop 0x874b6cc in string "VIRUS                                             "> start-open)
  text-prop-extent-paste-function(#<extent [0, 5) D paste-function text-prop 0x874b6cc in string "VIRUS                                             "> 413 418)

This is because text-prop-extent-paste-function is defined as:
{
  /* This function can GC */
  Lisp_Object prop, val;

  prop = Fextent_property (extent, Qtext_prop, Qnil);
  if (NILP (prop))
    signal_simple_error ("internal error: no text-prop", extent);
  val = Fextent_property (extent, prop, Qnil);
!!if (NILP (val))
!!  signal_simple_error_2 ("internal error: no text-prop",
!!			   extent, prop);
  Fput_text_property (from, to, prop, val, Qnil);
  return Qnil; /* important! */
}

Noet the lines with '!!' in front of them.  This basically means that you
cannot have a text-property with a 'nil' value, _EVER_.  Even if this is
what you want.  In the case of start-open, this is _EXACTLY_ what I want in
Emacs-W3.

I would vote for removing those lines from the function - seems to me you
should just propogate whatever value is slapped into the text property.
The first check (for whether we have a Qtext_prop property or not) is still
valid and should stay.

Oh pleeeease pleeeeease pleeeeease, don't make me beg - its unseemly.

-Bill P.

