* fontification in C++ mode
@ 2010-10-11 15:31 Alexander Klimov
2010-10-16 20:29 ` Alan Mackenzie
2010-10-19 20:51 ` Alan Mackenzie
0 siblings, 2 replies; 5+ messages in thread
From: Alexander Klimov @ 2010-10-11 15:31 UTC (permalink / raw)
To: Alan Mackenzie; +Cc: emacs-devel
Hi.
> If any C hacker (or even better, C++ hacker) notices anything else
> wrong, please let me know.
Consider
int main(){
}
In C++ mode (unlike C mode), "main" is no longer decorated as a
function-name (in bzr emacs, 2010-10-11).
--
Regards,
ASK
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: fontification in C++ mode
2010-10-11 15:31 fontification in C++ mode Alexander Klimov
@ 2010-10-16 20:29 ` Alan Mackenzie
2010-10-28 9:57 ` Alexander Klimov
2010-10-19 20:51 ` Alan Mackenzie
1 sibling, 1 reply; 5+ messages in thread
From: Alan Mackenzie @ 2010-10-16 20:29 UTC (permalink / raw)
To: Alexander Klimov; +Cc: emacs-devel
Hi Alexander,
On Mon, Oct 11, 2010 at 05:31:36PM +0200, Alexander Klimov wrote:
> Hi.
> > If any C hacker (or even better, C++ hacker) notices anything else
> > wrong, please let me know.
> Consider
> int main(){
> }
> In C++ mode (unlike C mode), "main" is no longer decorated as a
> function-name (in bzr emacs, 2010-10-11).
Thanks for taking the trouble to report this! It's a straightforward
bug, which I'll fix just as soon as I get access to the project's
repository again.
> --
> Regards,
> ASK
--
Alan Mackenzie (Nuremberg, Germany).
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: fontification in C++ mode
2010-10-16 20:29 ` Alan Mackenzie
@ 2010-10-28 9:57 ` Alexander Klimov
2010-10-31 13:34 ` Alan Mackenzie
0 siblings, 1 reply; 5+ messages in thread
From: Alexander Klimov @ 2010-10-28 9:57 UTC (permalink / raw)
To: Alan Mackenzie; +Cc: emacs-devel
Hi.
===
void f(const A& b){}
===
`f' is not treated as a function name. Note that it is not on the
first line of a file and it is the last definition.
===
void a(const A& b){}
void b(const A& b){}
===
Here both function names are not treated.
Btw, I guess it is a good idea to get some c++ sources, dump faces as
produced by emacs-23, normalize and diff with the current version,
e.g., (buffer-substring 1 (point-max)) in emacs-23.1 gives
#("
void b(const A& b){}
" 0 1 (fontified t) 1 4 (fontified t face font-lock-type-face) 4 5
(fontified t c-type c-decl-id-start face font-lock-type-face) 5 6
(fontified t) 6 7 (fontified t face font-lock-function-name-face) 7 8
(fontified t c-type c-decl-arg-start) 8 13 (fontified t face
font-lock-keyword-face) 13 14 (fontified t) 14 15 (fontified t face
font-lock-type-face) 15 17 (fontified t) 17 18 (fontified t face
font-lock-variable-name-face) 18 22 (fontified t) 22 23 (fontified t))
while in the current version it gives
#("
void b(const A& b){}
" 0 1 (fontified t) 1 5 (fontified t face font-lock-type-face) 5 7
(fontified t) 7 8 (fontified t) 8 13 (fontified t face
font-lock-keyword-face) 13 14 (fontified t) 14 15 (fontified t face
font-lock-type-face) 15 17 (fontified t) 17 18 (fontified t face
font-lock-variable-name-face) 18 22 (fontified t) 22 23 (fontified t))
--
Regards,
ASK
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: fontification in C++ mode
2010-10-28 9:57 ` Alexander Klimov
@ 2010-10-31 13:34 ` Alan Mackenzie
0 siblings, 0 replies; 5+ messages in thread
From: Alan Mackenzie @ 2010-10-31 13:34 UTC (permalink / raw)
To: Alexander Klimov; +Cc: emacs-devel
Hi, Alexander,
I'm looking at this. Thanks for such a nice bug report!
On Thu, Oct 28, 2010 at 11:57:53AM +0200, Alexander Klimov wrote:
> Hi.
> ===
> void f(const A& b){}
> ===
> `f' is not treated as a function name. Note that it is not on the
> first line of a file and it is the last definition.
> ===
> void a(const A& b){}
> void b(const A& b){}
> ===
> Here both function names are not treated.
> Regards,
> ASK
--
Alan Mackenzie (Nuremberg, Germany).
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: fontification in C++ mode
2010-10-11 15:31 fontification in C++ mode Alexander Klimov
2010-10-16 20:29 ` Alan Mackenzie
@ 2010-10-19 20:51 ` Alan Mackenzie
1 sibling, 0 replies; 5+ messages in thread
From: Alan Mackenzie @ 2010-10-19 20:51 UTC (permalink / raw)
To: Alexander Klimov; +Cc: emacs-devel
Hi Alexander,
On Mon, Oct 11, 2010 at 05:31:36PM +0200, Alexander Klimov wrote:
> Hi.
>
> > If any C hacker (or even better, C++ hacker) notices anything else
> > wrong, please let me know.
>
> Consider
>
> int main(){
> }
>
> In C++ mode (unlike C mode), "main" is no longer decorated as a
> function-name (in bzr emacs, 2010-10-11).
I've just committed a patch for this bug (in cc-langs.el). Please
recompile ALL the cc-*.el files before trying this out. :-)
Thanks once again for reporting this bug!
> --
> Regards,
> ASK
--
Alan Mackenzie (Nuremberg, Germany).
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2010-10-31 13:34 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-10-11 15:31 fontification in C++ mode Alexander Klimov
2010-10-16 20:29 ` Alan Mackenzie
2010-10-28 9:57 ` Alexander Klimov
2010-10-31 13:34 ` Alan Mackenzie
2010-10-19 20:51 ` Alan Mackenzie
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.