Author Topic: Bug Syntax Highlighting a Comment within a C macro  (Read 3197 times)

Offline ftabba

  • Single posting newcomer
  • *
  • Posts: 4
Bug Syntax Highlighting a Comment within a C macro
« on: July 29, 2008, 07:47:24 am »
Hi,

I read the sticky post on reporting bugs; so hopefully I got it right :)

Let me start by saying job well done. Last time I tried code:blocks was about a year ago and I wasn't too satisfied, but I downloaded it again yesterday and I think it's great.

Anyway, I found a syntax highlighting bug in C macros if they contain a comment, where the comment sort of breaks syntax highlighting out of macro mode:-

Code
#define MACRO green /*grey*/ normal highlighting

#define MACRO \
        green /*grey*/ normal \
        highlighting

If you paste the code above in a C file, the whole bit should be green since it's a macro, the comment grey is part of the macro itself. However, in code:blocks the comment grey break the highlighting out of macro mode.

The version I'm using is 8.02-0ubuntu1 by the way.

Keep up the good work!
/Fuad


Offline Wolf

  • Multiple posting newcomer
  • *
  • Posts: 30
Re: Bug Syntax Highlighting a Comment within a C macro
« Reply #1 on: August 08, 2008, 11:54:15 pm »
This is a bug with Scintilla's lexer. I can reproduce it in Notepad++, which also uses Scintilla as a syntax highlighter.