[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: forward-comment and syntax-ppss
From: |
Stefan Monnier |
Subject: |
Re: forward-comment and syntax-ppss |
Date: |
Sat, 10 Dec 2016 19:24:46 -0500 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (gnu/linux) |
> It's better in one sense and worse in another. Since parse-partial-sexp
> can't parse backwards, you're leaving a whole range of values of POS on
> which syntax-ppss will have to just raise an error.
I don't think it's a big deal: such a situation would necessarily be an
error elsewhere, so signaling an error would be the right thing to do anyway.
Admittedly, an alternative would be to provide syntax-ppss with a bunch
of "forced data", i.e. an alist of (POS . STATE) where syntax-ppss
should start parsing from the nearest earlier POS and use the
corresponding STATE as starting state. But it's probably not worth
the trouble (and might even be slightly problematic for (syntax-ppss
POS) since some callers would want it to return STATE while others might
like to know "the state computed from the earlier POS&STATE").
Stefan
- Re: forward-comment and syntax-ppss, (continued)
- Re: forward-comment and syntax-ppss, Andreas Röhler, 2016/12/10
- Re: forward-comment and syntax-ppss, Dmitry Gutov, 2016/12/08
- Re: forward-comment and syntax-ppss, Stefan Monnier, 2016/12/08
- Re: forward-comment and syntax-ppss, Andreas Röhler, 2016/12/09
- Re: forward-comment and syntax-ppss, Alan Mackenzie, 2016/12/09
- Re: forward-comment and syntax-ppss, Dmitry Gutov, 2016/12/09
- Re: forward-comment and syntax-ppss,
Stefan Monnier <=
- Re: forward-comment and syntax-ppss, Alan Mackenzie, 2016/12/11
- Re: forward-comment and syntax-ppss, Andreas Röhler, 2016/12/11
- Re: forward-comment and syntax-ppss, Dmitry Gutov, 2016/12/15
- RE: forward-comment and syntax-ppss, Drew Adams, 2016/12/15
- Re: forward-comment and syntax-ppss, Eli Zaretskii, 2016/12/16
- RE: forward-comment and syntax-ppss, Drew Adams, 2016/12/16
- Re: forward-comment and syntax-ppss, Eli Zaretskii, 2016/12/16
- RE: forward-comment and syntax-ppss, Drew Adams, 2016/12/16
- Re: forward-comment and syntax-ppss, Dmitry Gutov, 2016/12/16
- RE: forward-comment and syntax-ppss, Drew Adams, 2016/12/16