News for hackers. Stuff that matters.
Re:The C++ Build Process Explained by MaxBarraclough on Thursday November 15, 2018 @09:37AM (#18459499)
Header-generator tools are out there, but I'm not sure how usable they are. It's rarely done though. It's a bit of a pain having to 'write everything twice', but there's more to header files than re-declaring what you've done in your source files.

As berti said: enums, constants, macros, simple struct type declarations, typedefs, and templates, are examples of hand-written code that might belong entirely in the header file.

It would be possible to keep these constructs in a hand-written header file while auto-generating the rest, but C++ developers aren't convinced this is worth doing.

There are no comments on this comment yet.