From mboxrd@z Thu Jan 1 00:00:00 1970 From: Leo Subject: Re: Bug: Clock data and log messages no longer in drawers [6.36trans (release_6.36.7.gae1eb)] Date: Mon, 10 May 2010 22:05:17 +0100 Message-ID: References: <87zl076ceu.fsf@gollum.intra.norang.ca> <877hnb7fs1.fsf@gollum.intra.norang.ca> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from [140.186.70.92] (port=60591 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OBaAF-0004aQ-H6 for emacs-orgmode@gnu.org; Mon, 10 May 2010 17:05:24 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OBaAD-0007lk-AM for emacs-orgmode@gnu.org; Mon, 10 May 2010 17:05:23 -0400 Received: from ppsw-52.csi.cam.ac.uk ([131.111.8.152]:33869) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OBaAD-0007lW-2a for emacs-orgmode@gnu.org; Mon, 10 May 2010 17:05:21 -0400 In-Reply-To: <877hnb7fs1.fsf@gollum.intra.norang.ca> (Bernt Hansen's message of "Mon, 10 May 2010 14:50:06 -0400") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Bernt Hansen Cc: emacs-orgmode@gnu.org, Carsten Dominik On 2010-05-10 19:50 +0100, Bernt Hansen wrote: > Actually I got this to occur both in emacs 22 and on an older version of > Emacs 23 on windows today. > > GNU Emacs 23.1.50.1 (i386-mingw-nt5.1.2600) of 2009-11-03 on > LENNART-69DE564 (patched) > > GNU Emacs 22.2.1 (i486-pc-linux-gnu, GTK+ Version 2.12.11) of 2008-11-09 > on raven, modified by Debian > > Regards, > Bernt You are right. Sorry I didn't use the clock in/out much. The problem is once :CLOCK: is inserted the second run doesn't trigger the problem any more. Could you try the patch below and see if it fixes the issue? The cause: After changing the syntax of \n to mean the end of comment, it is no longer a whitespace. Thus regexp like \S- will match it. Unfortunately we didn't fix the comment-end syntax earlier so regexps relying on syntax might be different. But I believe it is still better setting a correct comment end and fixing the rest. Carsten, could you check whether the following change still matches the full set of properties allowed? diff --git a/lisp/org/org.el b/lisp/org/org.el index 96b4145..9727852 100644 --- a/lisp/org/org.el +++ b/lisp/org/org.el @@ -16976,12 +16976,12 @@ which make use of the date at the cursor." (save-excursion (org-indent-line-to column))) (setq column (current-column)) (beginning-of-line 1) - (if (looking-at - "\\([ \t]+\\)\\(:[-_0-9a-zA-Z]+:\\)[ \t]*\\(\\S-.*\\(\\S-\\|$\\)\\)") - (replace-match (concat (match-string 1) - (format org-property-format - (match-string 2) (match-string 3))) - t t)) + (when (re-search-forward "\\([ \t]+\\)\\(:[-_0-9a-zA-Z]+:\\)[ \t]*\\(\\S-.*\\S-\\)" + (line-end-position) t) + (replace-match (concat (match-string 1) + (format org-property-format + (match-string 2) (match-string 3))) + t t)) (org-move-to-column column))) (defun org-set-autofill-regexps ()