emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: problem of marker as position


From: Kevin Rodgers
Subject: Re: problem of marker as position
Date: Thu, 20 Nov 2003 12:41:16 -0700
User-agent: Mozilla/5.0 (X11; U; SunOS i86pc; en-US; rv:0.9.4.1) Gecko/20020406 Netscape6/6.2.2

Robert J. Chassell wrote:

I am a native English speaker and, to my embarrassment, have been
confused.  Extra explanation is useful, since the notion of marker
encompasses two different concepts:

  1. a position within a buffer that relocates automatically when
text is inserted or deleted,
  2. a specification of which buffer the position is within.

My problem is that sometimes, I focus on concept # 2 when the person
writing the code focuses on concept # 1 --- I should, of course, focus
on both concepts, but forget.  A better explanation would help me
remember.

The two concepts cannot be separated because the position must be
within a particular buffer.

Indeed.  It would be interesting to add debugging code to marker.c
(analagous to byte_char_debug_check) that would signal an error if any
marker was being used as a position in a different buffer.  If there
aren't too many cases, it'd be simple to convert the references to the
marker M to (marker-position M).  Then the run-time check could be left
in for Lisp programmers, dependent upon a variable (analgous to
byte-debug-flag).

--
Kevin Rodgers






reply via email to

[Prev in Thread] Current Thread [Next in Thread]