emacs-devel
[Top][All Lists]
Advanced

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

Re: Musings: Supposed places of safety, guaranteed by parse-partial-sexp


From: Daniel Colascione
Subject: Re: Musings: Supposed places of safety, guaranteed by parse-partial-sexp are not safe.
Date: Sat, 03 Dec 2011 15:40:25 -0800
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:8.0) Gecko/20111105 Thunderbird/8.0

On 12/3/11 3:23 PM, Alan Mackenzie wrote:
> I think it would be a good idea to provide a function to test for this
> "half comment" state, somewhat like `syntax-ppss-toplevel-pos'.  This
> new defun could be called something like
> `syntax-ppss-comment-half-opener' and calling it would return nil
> usually, but ?/ in these circumstances.
> 
> What do other people think?

Why not just scan one character further ahead, using the previous position and
parse state, to see whether you then enter a comment?

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

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