3 ms·
Afaik this is exactly what Unity builds are. https://en.wikipedia.org/wiki/Unity_build https://en.wikipedia.org/wiki/Unity_build
by jariRG 4y ago
Afaik this is exactly what Unity builds are.
https://en.wikipedia.org/wiki/Unity_build https://en.wikipedia.org/wiki/Unity_build
- unsafecast 4y agoYeah. Though most projects still use header files with unity builds, so I decided not to call them that. It wasn't the concept of a unity build that I was emphasising, it was the idea of not forward-declaring everything.
- arinlen 4y ago> Yeah. Though most projects still use header files with unity builds, so I decided not to call them that. There is nothing inherently special in header files. They are just a convention where you use a specific extension in source files you mostly use to pass declarations. Nothing stops you from using the .c extension on all files, and there is nothing special in passing declarations in one place and definitions in another place.
- unsafecast 4y agoOf course! But, saying 'unity build' puts emphasis on the fact that you compile all the C files 'in unity', in a single CU. What _I_ wanted to put emphasis on is that you can skip the header files, and that coincidentally means you also have to unity build. The fact that most unity built projects still use headers made me hesitant to use the term, as that would put emphasis on building a single CU, as opposed to not forward declaring in headers.
- TingPing 4y agoBuild systems like Meson can even enable/disable this with an option ootb.