Re: [Boost-docs] Changes to syntax_highlight.hpp

Subject: Re: [Boost-docs] Changes to syntax_highlight.hpp
From: Joel de Guzman (joel_at_[hidden])
Date: 2007-08-09 00:09:16


Andreas Pokorny wrote:
> Hello,
> I joined the group of people helping to improve the boost
> documentation. I started adding three new color schemes,
> because I was not happy with the results I modified
> syntax_highlight.hpp:
>
> 1) Support for multiline macros and C-comments inside macros
> 2) #include "files" and <files> are treated as "preprocessor" and
> "string" tokens
> 3) separation of "keyword" in four groups:
> a) "types-keywords": builtin types, also some C99/boost-stdint types
> and typical typedef keywords
> b) "control-flow": keywords controling the program flow like for break return
> c) "operators": and or xor.. and C++ casts
> d) "keyword": the remaining keywords: virtual class union asm struct
> template private public...
>
> Can I commit that?
> Do you have objections regarding the keyword groups?
> Because I have :). I dont think that grouping them like that
> is very wise. I just had the feeling that at least two different
> groups should look at lot better than just one. Somehow
> there are now four different groups.

Hi Andreas,

Looks good. However,...

What I'd really want is to Regex-ify the syntax highlighter and
have them reconfigurable as user-supplied regex strings from
configuration files. This would simplify our life a lot. There'll
be only one syntax highlighter grammar and code that can accept
various lexer files. Our job then is just to churn out various
lexer files for different languages.

So, whatever you do with new lexer groupings, it must be
general enough for other languages too.

Would you like to work on the regexification?

Regards,

-- 
Joel de Guzman
http://www.boost-consulting.com
http://spirit.sf.net

This archive was generated by hypermail 2.1.7 : 2017-11-11 08:50:40 UTC