GNU bug report logs - #24172
25.1; Doc of parse-sexp-ignore-comments: what does a value of nil mean?

Previous Next

Package: emacs;

Reported by: Michael Heerdegen <michael_heerdegen <at> web.de>

Date: Sat, 6 Aug 2016 23:29:01 UTC

Severity: minor

Found in version 25.1

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


Message #8 received at 24172 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Michael Heerdegen <michael_heerdegen <at> web.de>
Cc: 24172 <at> debbugs.gnu.org
Subject: Re: bug#24172: 25.1; Doc of parse-sexp-ignore-comments: what does a
 value of nil mean?
Date: Sat, 27 Jul 2019 17:21:42 +0200
Michael Heerdegen <michael_heerdegen <at> web.de> writes:

> in the docstring of `parse-sexp-ignore-comments' (or at least in the
> manual), I miss a description about what a value of nil exactly means:
> How are comments treated then?  Are they treated as separate units that
> can then be parsed as well, but separately from code, or are they treated
> as indistinguishable from code?
>
> For example, if parsing starts from within a comment, and parsing finds
> the end of the comment and is not yet finished, is parsing just
> continued inside the following code, or does it fail?

After doing some testing, it seems that if it's nil, the commands
affected by the setting just treat the commented-out text as if it
wasn't commented out.

So the answer to your last question seems to be "yes".

;; (foo

(bar zot))

However, pretty much the same thing happens with a non-nil value, too --
with point before (foo C-M-f will advance past zot)).

So it doesn't treat comments as whitespace, really -- it only does that
if point is outside (before, at the end of a line, etc) the comment to
begin with.  Seems like you could write an essay about it, but perhaps
it's not worth listing the eccentricities here which I guess could change.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




This bug report was last modified 3 years and 261 days ago.

Previous Next


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