Skip to content
Kristina Chodorow's Blog

Kristina Chodorow's Blog

Snail in a Turtleneck

Tag Archives: compilers

A Neat C Preprocessor Trick

I’ve been looking at Clang and they define lexer tokens in a way that I thought was clever. The challenge is: how do you keep a single list of language tokens but use them as both an enum and a list of strings? Clang defines C token types in a file, TokenKinds.def, with all ofContinue reading “A Neat C Preprocessor Trick”

Posted bykchodorowAugust 24, 2012Posted inProgrammingTags:compilers4 Comments on A Neat C Preprocessor Trick

Subscribe to get new posts in your email:

Kristina Chodorow's Blog, Blog at WordPress.com.
  • Subscribe Subscribed
    Kristina Chodorow's Blog

    Have a WordPress.com account? Log in now.

  • Kristina Chodorow's Blog
    View site in Reader
    Manage subscriptionsSign upLog in
    Report this content
    Collapse this bar