From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Howard Melman Newsgroups: gmane.emacs.bugs Subject: bug#48317: 27.1; text-property-search-forward moves point to end when not found Date: Mon, 10 May 2021 09:06:08 -0400 Message-ID: <4E8819BD-AA07-4870-8A90-98FB1F3D45E4@gmail.com> References: <0ECAF0D9-7D8C-4BAA-AFFE-B76634BD0B28@gmail.com> <83o8dj7s48.fsf@gnu.org> <616F7732-ED83-40F0-A460-9298608EAD91@gmail.com> <83lf8n7q8d.fsf@gnu.org> <8877DDB9-7D2B-4DCC-8374-EB8391134EAC@gmail.com> <83fsyv7o4y.fsf@gnu.org> <87mtt3c62q.fsf@gnus.org> Mime-Version: 1.0 (Mac OS X Mail 13.4 \(3608.120.23.2.6\)) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="3052"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 48317@debbugs.gnu.org To: Lars Ingebrigtsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon May 10 15:07:15 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lg5cw-0000dE-C4 for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 10 May 2021 15:07:14 +0200 Original-Received: from localhost ([::1]:49592 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lg5cv-0008TP-7y for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 10 May 2021 09:07:13 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:46822) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lg5ck-0008QB-K4 for bug-gnu-emacs@gnu.org; Mon, 10 May 2021 09:07:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:46152) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lg5ck-0001az-D5 for bug-gnu-emacs@gnu.org; Mon, 10 May 2021 09:07:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lg5ck-0005DG-80 for bug-gnu-emacs@gnu.org; Mon, 10 May 2021 09:07:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Howard Melman Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 10 May 2021 13:07:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 48317 X-GNU-PR-Package: emacs Original-Received: via spool by 48317-submit@debbugs.gnu.org id=B48317.162065197819976 (code B ref 48317); Mon, 10 May 2021 13:07:02 +0000 Original-Received: (at 48317) by debbugs.gnu.org; 10 May 2021 13:06:18 +0000 Original-Received: from localhost ([127.0.0.1]:57698 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lg5c1-0005C8-Jn for submit@debbugs.gnu.org; Mon, 10 May 2021 09:06:17 -0400 Original-Received: from mail-qk1-f174.google.com ([209.85.222.174]:44898) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lg5bz-0005Bt-BM for 48317@debbugs.gnu.org; Mon, 10 May 2021 09:06:15 -0400 Original-Received: by mail-qk1-f174.google.com with SMTP id a2so15138711qkh.11 for <48317@debbugs.gnu.org>; Mon, 10 May 2021 06:06:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=qR9ZgmyFd5Zm2E100Lbysid1+KyYUjX6NH+4ynntHgs=; b=rQ1VHiwTQsEhohWxkPtriGotwC3T9X5Kt94lVADllO/hMXt9nLQsWUyNyLfQJIIiJT a03zETA8RAtz7Oy72E2TFy7z5ZP4GvjhODzlvzOo9zvnhM080pu5jv7BzXcufJ5CskYi yig+/63EQqbBNDEe4s7sdxKfWw5N84Xlh+QlBLS8CFY/6YhP6USR6jP/+s1KLddeKqEp cMkj02tNXtVIPwZnepkZDQYXdIkP/p8Bbglj0AaXPvod742qQj66z7TIIAAbTRW7DLhF O1xNiVTdGCDXD8ZhZGPwSxghJ5UkDrOJuZW1jZPKgtz71tgOYomTsVQ/8y+tFMWx99gF Io/w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=qR9ZgmyFd5Zm2E100Lbysid1+KyYUjX6NH+4ynntHgs=; b=fZ5zTQKFyUi6n/GwcrpB14kyttErpx7xiC2tRhNbThJKK5O+lscF1+v/2T9EliH1F2 /WZ9DSxFojylJyIHCvvyCSPXN4yX0p56qan/2lNptYtjMBYPZHL0JGL9cmq1eRI07pYm zjY5UppuNm9v/DwfMxOi6SYXtO6rVPtyxWq/bxbiAXKl/mt73XuUSty82ScTik+EmIdK kC2aoUa9yN0ju/LdQQ+nq6+5PQyP9b4KpbJWhMhMavhwIoPxdhDGqi15LooQv+9JCV21 gfAyAzKSXlxWG7mBDnstfTsOaTGXCnUw82p2MrJsEp01MXKfY4BKHJvPEoeTv5nHBgDZ DK/w== X-Gm-Message-State: AOAM531PhOxmLzH124Hi3wSIFeDL2UwehKs9ZlssGUF4f1IyqBmQX/J0 07yy9hw1MElvuhT3Dded3Ns= X-Google-Smtp-Source: ABdhPJxdHswB2mno+tSsiOViEUikcCrZ6rsukKGoXqB5mv1zlFO5kS87O1CBFA0jgl6yf/kYgCW7Yg== X-Received: by 2002:a05:620a:13d5:: with SMTP id g21mr5297645qkl.494.1620651969802; Mon, 10 May 2021 06:06:09 -0700 (PDT) Original-Received: from lumet2.home (pool-108-26-204-101.bstnma.fios.verizon.net. [108.26.204.101]) by smtp.gmail.com with ESMTPSA id b1sm9427192qtt.67.2021.05.10.06.06.08 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Mon, 10 May 2021 06:06:09 -0700 (PDT) In-Reply-To: <87mtt3c62q.fsf@gnus.org> X-Mailer: Apple Mail (2.3608.120.23.2.6) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:206151 Archived-At: On May 10, 2021, at 5:05 AM, Lars Ingebrigtsen wrote: > I think the doc string is wrong -- you rewrote it in 165890a and = further > in df05c26. The original doc string was correct, I think: >=20 > +Some convenience values for PREDICATE can also be used. `t' > +means the same as `equal'. `nil' means almost the same as \"not > +equal\", but will also end the match if the value of PROPERTY > +changes. See the manual for extensive examples. >=20 > The code performs as originally documented in the test case from = Howard, > as far as I can tell. Ok, setting property to t solves both of my cases. What threw me (and I still think is problematic) is this line from the = docstring: If not found, return nil and don't move point. And this line from the manual: If the text property can=E2=80=99t be found, the function returns = =E2=80=98nil=E2=80=99. Which I assume also infers point is not moved. If no region has the = named property I can't see how it can be found and therefore point = should not be moved. In fact I don't see how predicate even comes into = play in this case. =20 I still think there's a bug here: ;; We're standing in the property we're looking for, so find the ;; end. ((and (text-property--match-p value (get-text-property (point) = property) predicate) (not not-current)) (text-property--find-end-forward (point) property value predicate)) Because this solves my problem: ((and (get-text-property (point) property) (text-property--match-p value (get-text-property (point) = property) predicate) (not not-current)) (text-property--find-end-forward (point) property value predicate)) Howard=