[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Mysterious fontification/C++ context issue
From: |
Stefan Monnier |
Subject: |
Re: Mysterious fontification/C++ context issue |
Date: |
Sun, 10 Dec 2006 20:29:53 -0500 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.0.91 (gnu/linux) |
> beginning-of-defun unfortunately conflates (i) "beginning of a function" and
> (ii) "outermost level of parens", this arising because they coincide in
> the most important language (Lisp). Having
> "beginning-of-defun-function" makes things even worse.
If you want a reliable solution for (ii), then use syntax-ppss (e.g. use the
syntax-ppss-toplevel-pos I proposed yesterday).
Beginning-of-defun *does not* conflate the two. It has always been defined
as the meaning (i). In just so happens that for performance reasons, people
have used it as a heuristic in syntax-begin-function to get an approximation
of (ii). If you don't want that approximation, then don't set
syntax-begin-function.
Stefan
- Re: Mysterious fontification/C++ context issue, (continued)
- Re: Mysterious fontification/C++ context issue, Richard Stallman, 2006/12/06
- Re: Mysterious fontification/C++ context issue, martin rudalics, 2006/12/06
- Re: Mysterious fontification/C++ context issue, Richard Stallman, 2006/12/08
- Re: Mysterious fontification/C++ context issue, martin rudalics, 2006/12/09
- Re: Mysterious fontification/C++ context issue, Richard Stallman, 2006/12/09
- Re: Mysterious fontification/C++ context issue, martin rudalics, 2006/12/10
- Re: Mysterious fontification/C++ context issue, Alan Mackenzie, 2006/12/10
- Re: Mysterious fontification/C++ context issue, martin rudalics, 2006/12/10
- Re: Mysterious fontification/C++ context issue, Slawomir Nowaczyk, 2006/12/10
- Re: Mysterious fontification/C++ context issue,
Stefan Monnier <=
Re: Mysterious fontification/C++ context issue, Alan Mackenzie, 2006/12/06