3 ms·
I don't really understand what your criticisms are. There is literally no functional code difference between a single header library and a two file library. You
by jeremycw 7y ago
I don't really understand what your criticisms are. There is literally no functional code difference between a single header library and a two file library. Your aversion is as arbitrary as saying you don't consider libraries if the API uses camel case.
- Athas 7y agoCan you compile a header to an object file so that its definitions don't have to be recompiled every time the including file is recompiled?
- shakna 7y agoEh... Yes? GCC [0], Clang [1] and others [2] have supported for compiled headers. Cmake also has support for precompiled headers [3]. I would say both the tool and architecture to do that is well supported. [0] https://gcc.gnu.org/onlinedocs/gcc/Precompiled-Headers.html https://gcc.gnu.org/onlinedocs/gcc/Precompiled-Headers.html [1] https://clang.llvm.org/docs/PCHInternals.html https://clang.llvm.org/docs/PCHInternals.html [2] https://www.qnx.com/developers/docs/6.3.2/neutrino/utilities/i/icc.html https://www.qnx.com/developers/docs/6.3.2/neutrino/utilities... (-pch flag) [3] https://cmake.org/cmake/help/latest/command/target_precompile_headers.html https://cmake.org/cmake/help/latest/command/target_precompil...
- pjmlp 7y agoOther than not being able to use pseudo-modules in C, using a gigantic header file instead.