From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: David Kastrup Newsgroups: gmane.emacs.devel Subject: Mule problem. Date: 20 Aug 2004 22:05:09 +0200 Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Message-ID: NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1093032344 21585 80.91.224.253 (20 Aug 2004 20:05:44 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 20 Aug 2004 20:05:44 +0000 (UTC) Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Aug 20 22:05:31 2004 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1ByFdj-0007ZV-00 for ; Fri, 20 Aug 2004 22:05:31 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1ByFi2-000448-Ma for ged-emacs-devel@m.gmane.org; Fri, 20 Aug 2004 16:09:58 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.33) id 1ByFhw-000442-IW for emacs-devel@gnu.org; Fri, 20 Aug 2004 16:09:52 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.33) id 1ByFhv-00043c-27 for emacs-devel@gnu.org; Fri, 20 Aug 2004 16:09:52 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1ByFhu-00043Z-UW for emacs-devel@gnu.org; Fri, 20 Aug 2004 16:09:51 -0400 Original-Received: from [199.232.76.164] (helo=fencepost.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.34) id 1ByFdP-0002MK-48 for emacs-devel@gnu.org; Fri, 20 Aug 2004 16:05:11 -0400 Original-Received: from localhost ([127.0.0.1] helo=lola.goethe.zz) by fencepost.gnu.org with esmtp (Exim 4.34) id 1ByFdO-0000iK-Ft for emacs-devel@gnu.org; Fri, 20 Aug 2004 16:05:11 -0400 Original-To: emacs-devel@gnu.org Original-Lines: 30 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:26348 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:26348 What is the most efficient possibility of encoding or decoding regions in a buffer while keeping markers intact? Or, somewhat differently put: assuming that I have a conceptional marker at every character, what happens to those markers? Effectively I need to correlate error messages from a TeX compiler run with stuff in the source buffer, and TeX has the bad habit of not looking at characters but bytes in its source, and also of transcribing some input characters into hexadecimal instead of keeping them. So I basically have to take the buffer line, convert it into a canonical form based on the byte sequence, take all the error messages, convert them into canonical form, too, correlate the errors in the messages with the canonical form, and then convert everything back. It would be most efficient if I could just place markers at the points of all error, and then call undo repeatedly until I arrive back at the original buffer line, then take a look at where the markers winded up. Unfortunately, this does not work. If the conversion functions could be given a (sorted) array of string positions, and would record where those positions moved to upon conversion, this would help quite a bit. Any idea of how to work this at the moment? -- David Kastrup, Kriemhildstr. 15, 44793 Bochum