emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: master 305dbc7 2/4: Move description of value to syntax-ppss functio


From: Dmitry Gutov
Subject: Re: master 305dbc7 2/4: Move description of value to syntax-ppss function.
Date: Sat, 15 Feb 2020 17:14:31 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.9.0

On 15.02.2020 16:55, Noam Postavsky wrote:

-  (comment-nesting nil :documentation "\
+  (comment nil :documentation "\

Doesn't this name imply some other value? Like a string (comment opener
or its contents)?

Hmm, you might be right about that. How about 'comment-depth': two
characters shorter, and the other names also use "depth" rather than
"nesting".

Sounds good.

-  (open-paren-positions
+  (open-parens
      nil :documentation
      "List of positions of currently open parens, outermost first.")
-  (two-character-syntax nil :documentation "\
+  (syntax-sequence nil :documentation "\
   When the last position scanned holds the first character of a
   (potential) two character construct, the syntax of that position,
   otherwise nil.  That construct can be a two character comment

These look okay to me.

I'm actually feeling that the two-character-syntax one should be left
as is, it's kind of obscure so having a longer and more explicit name
seems better.

Agree (I also have never used it).

min-depth too, but, like last-complete-sexp-start, these fields in
values returned by syntax-ppss are unreliable/undefined, so they won't
be used in most Lisp programs anyway.

I might be biased by having worked on the lisp indentation code which
uses those fields quite a bit.

So... Lisp indentation code calls parse-partial-sexp directly?

Anyway, I said min-depth is okay, but if we're going to have comment-depth, maybe min-depth starts to sound more ambiguous.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]