logoalt Hacker News

WalterBrightlast Monday at 11:37 PM1 replyview on HN

Pedantically, the preprocessor is an entirely separate language. The lexing, parsing, expressions, and semantics are totally distinct. The preprocessor is usually implemented as a completely independent program. My first C compiler did integrate the preprocessor with the C compiler, but that was for performance reasons.

Currently, ImportC runs cpp and then lexes/parses the resulting C code for use in D.


Replies

ryaoyesterday at 1:05 AM

It is part of the C standard. Whether it is part of a separate binary is an implementation choice.

show 1 reply