From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id gKxkD27iAGedJwAAe85BDQ:P1 (envelope-from ) for ; Sat, 05 Oct 2024 06:53:34 +0000 Received: from aspmx1.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id gKxkD27iAGedJwAAe85BDQ (envelope-from ) for ; Sat, 05 Oct 2024 08:53:34 +0200 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20230601 header.b=aLHjULbc; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=gmail.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1728111214; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=pUVLZVmYjAMUE5eSQG57FKFFlCKIwIDhCCDCKemBXZw=; b=POmOrBYqrRQf0E7fcrZTgLiTwXiWGVypUmVbsDPDzEGKXf1o64t74u18m/G16TGdMcX/Bv KVKFGeyb1xabz+kE+4P3GmyDPOuQaw5gTGHxNEheuEmZm5ZHffTB5dsq0SFAAexcbPTeS7 9+elnNfq8w/mm1M+sg7Y5oRtvlFMVt6U1zwt2OrEoftWvvjf6sDDKhAvSNY22YklhLs9GA wuSq/1k5LIaSAHGlYkH3ipzIXasq4yFu3tg2p2ug/VEvSXBQpY7bXlsqud7LcjB2T8MhZe fpuCH0/7qar2Y8Mogn0ww8/ECZ14KwqxrCAoVGbFmOrT+KWY2frYjDIUrIIjrQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1728111214; a=rsa-sha256; cv=none; b=V5jCXn2ZfS7RYUMNCtsoJy5gex5ivZG4FMcUvJyCvwDawz5q4y2Vcdqzntbu1xwghzuAYd AUSxHAJXrMmob3eAYi1WbXpMVJXYIdbIOTUMBsXY9EqDSrAko7lsqTEioDU3cLUduRNxqM +I39UjyvLkLHZhY6yiz4xD3yye2oB/tCIagfggnUcZ4H5yjf5AiMVAXc/hZl8hokT69K4n UfOTFY+C+VEewnRnXkIie59lQ4HS0WqQxquEyu1QfyaxQ6HINFCOe4KSFmbIz3z5s0XN5x kzDHqAytLkv/pUB9JaDlNVIh5LQXQVfnuQuc8sy3ItPYXEBWhRXCEyHF8zaVUw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20230601 header.b=aLHjULbc; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=gmail.com Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id E9501BEA for ; Sat, 05 Oct 2024 08:53:33 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1swyeZ-0007lR-RP; Sat, 05 Oct 2024 02:52:36 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1swyeV-0007l2-9Z for emacs-orgmode@gnu.org; Sat, 05 Oct 2024 02:52:32 -0400 Received: from mail-yb1-xb34.google.com ([2607:f8b0:4864:20::b34]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1swyeS-00052Q-TP for emacs-orgmode@gnu.org; Sat, 05 Oct 2024 02:52:30 -0400 Received: by mail-yb1-xb34.google.com with SMTP id 3f1490d57ef6-e288efeb4feso2131648276.3 for ; Fri, 04 Oct 2024 23:52:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1728111146; x=1728715946; darn=gnu.org; h=to:subject:message-id:date:from:mime-version:from:to:cc:subject :date:message-id:reply-to; bh=pUVLZVmYjAMUE5eSQG57FKFFlCKIwIDhCCDCKemBXZw=; b=aLHjULbcjm9ELHIJncKWLvEv3rve3qZYCcGiFYC2VtDwUe8oiufWD6YaXtrMV11EgT 2ZGgWSwPvSin0v3eWW9YzeSK8nhJhrOMfGmxo/AGY/g6txQ+V0XMDLlalSzpFeK6d4EI u8mvU0SyRbpuXok9chLXgW6SyEiZK6z+XOZp5ScuUkduVNujyx6R2Ud79GYbokys/vyq YD4YIXnbP925+yrTtMWzsM+vm0PuWkBrYyPw0z7Hjp+CGz3Gpf6Hs7rjtGw0fYEue/1I HD56xutE7nRGLmC5+LPp0VF5RPVfrH5S2eB1pA3o/6UllQRvWEFkXMp6ca5LlSF9sL79 XoLA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1728111146; x=1728715946; h=to:subject:message-id:date:from:mime-version:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=pUVLZVmYjAMUE5eSQG57FKFFlCKIwIDhCCDCKemBXZw=; b=LttkBSpJ8AcdKrJDlfu0/gCi6UpmEEUHtwvuuyFSGZMepLDwHxMGHgsvhYbq3GJPN6 2a0WL6O9b5LTfzEb1rQauX5Uj9BAdqkheRkfwS6v6WxHgnwPijivGauNjvPPNhQMtfvq fvogPV4c3ngZONiQDPrHLt/jmcVGRIUTcOK20KZSYHT8ntjJccvl+B16vGd3qVAIhvmu s+QzPHoPju+/FsaOZKjY0By5xOuelsIVW/fEKbI6iv5p70tQXlT6w/Kw7psCa6uA+xQO hKvvMmkegiTYrkhXuIG9JC7PN3QWf7xz9mIK2AwVVD27B1+EqoC2BU8ZfsRc5qJcYoEt brGQ== X-Gm-Message-State: AOJu0YzxXSLSSiGph+brzX35FtdSCsBzTevkoUZv6yjSRq5i0lV/AL3A yurK3DbTtf1IW3p0yH3tE/8eSp1I3xim21z8Feqhb7lbiyFwF8OEPPyVOSjo5FxcJXxc3cPkwI7 TdN+YMXamwDay2KFKUYfJ/17QbIsw0S+E X-Google-Smtp-Source: AGHT+IGnEj75baXq/7tacR/gNlCVbCHfMti0kIVMhL+z9g3N+oPRjk3PgfPy7F9zaue7s3RODyrlkvNv+cVNVEkkqsQ= X-Received: by 2002:a05:6902:27c7:b0:e22:5b5b:58ad with SMTP id 3f1490d57ef6-e2893944237mr4509182276.54.1728111146453; Fri, 04 Oct 2024 23:52:26 -0700 (PDT) MIME-Version: 1.0 From: Benjamin McMillan Date: Sat, 5 Oct 2024 15:52:00 +0900 Message-ID: Subject: [BUG] A call of (org-end-of-meta-data t) goes too far in a heading with only whitespace To: emacs-orgmode@gnu.org Content-Type: multipart/alternative; boundary="00000000000004525d0623b53bb9" Received-SPF: pass client-ip=2607:f8b0:4864:20::b34; envelope-from=mcmillanbb@gmail.com; helo=mail-yb1-xb34.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Spam-Score: -2.57 X-Spam-Score: -2.57 X-Migadu-Queue-Id: E9501BEA X-Migadu-Scanner: mx13.migadu.com X-TUID: qP0MovBxiW+N --00000000000004525d0623b53bb9 Content-Type: text/plain; charset="UTF-8" Specifically, a call to (org-end-of-meta-data t) with point at the > on the following tree will go all the way to the next heading. In contrast, a call to just (org-end-of-meta-data), without the FULL flag, will go to the beginning of heading content, as expected. * >heading * another heading The issue arises from the code for skipping clock lines, which does so by checking if point is looking at (concat "[ \t]*$" "\\|" org-clock-line-re). I'm not sure of the intention of the first alternative, the "[ \t]*$", but it matches an empty line, and so the loop advances point to the next line, until reaching the next heading in the case above. Removing that from the regexp appears to fix the issue. If this change is fine, then I am happy to provide a patch. Thanks, Ben --00000000000004525d0623b53bb9 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Specifically, a call to (org-end-of-meta-data t) with poin= t at the > on the following tree will go all the way to the next heading= .
In contrast, a call to just (org-end-of-meta-data), without the FULL f= lag, will go to the beginning of heading content, as expected.
* >hea= ding


* another heading


The issue arises from the code= for skipping clock lines, which does so by checking if point is looking at= (concat "[ \t]*$" "\\|" org-clock-line-re).
I'm= not sure of the intention of the first alternative, the "[ \t]*$"= ;, but it matches an empty line, and so the loop advances point to the next= line, until reaching the next heading in the case above.
Removing = that from the regexp appears to fix the issue.

If = this change is fine, then I am happy to provide a patch.
Than= ks,
Ben
--00000000000004525d0623b53bb9--