3 ms·
I've spent the last 2 years writing an age of empires 2 clone in C: github.com/glouw/openempires and my time spent with C has really just been manually implem
by glouwbug 7y ago
I've spent the last 2 years writing an age of empires 2 clone in C:
github.com/glouw/openempires
and my time spent with C has really just been manually implementing min heaps, circular buffers, ad hoc vectors, and a tier 1 dummy garbage collector.
All this stuff is readily available in C++, and I could have saved hundreds of hours by just using C++.
But, to one benefit, since I did all this work myself, I understand the machine better, and my compilation times are orders of magnitude faster than what I would have had if I chose C++. Additionly, since so few calls are even being made to the C standard library, the majority of the code exists in text, and easily inlines across all translations units with link time optimization. With C++, as except for templated library code, the majority of link time optimizations go to waste as calls to the standard library are binary linked.