GNU bug report logs - #28428
comment-search-backward with no comments

Previous Next

Package: emacs;

Reported by: "N. Raghavendra" <raghu <at> hri.res.in>

Date: Mon, 11 Sep 2017 22:38:02 UTC

Severity: normal

Fixed in version 27.1

Done: Stefan Monnier <monnier <at> IRO.UMontreal.CA>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Stefan Monnier <monnier <at> IRO.UMontreal.CA>
To: "N. Raghavendra" <raghu <at> hri.res.in>
Cc: 28428 <at> debbugs.gnu.org
Subject: bug#28428: comment-search-backward with no comments
Date: Fri, 22 Sep 2017 15:26:58 -0400
>> That looks fine, thank you.  But I think the simpler patch below works
>> as well:
>> -  (if (not (re-search-backward comment-start-skip limit t))
>> +  (if (not (re-search-backward comment-start-skip limit 'move))
> That's indeed nicer!  Thanks for pointing out that the NOERROR arg of
> `re-search-backward' can be given a value outside {t,nil} to move point
> to LIMIT.  It's a lesson to myself that I should read docstrings more
> carefully.

I think it's too risky for the emacs-26 branch, but feel free to install
it on master,


        Stefan




This bug report was last modified 7 years and 328 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.