C vs. C++ vs. ...
Posted Jul 1, 2012 19:03 UTC (Sun) by khim
In reply to: C vs. C++ vs. ...
Parent article: Why learn C? (O'Reilly Radar)
Uhm. 10000 classes probably mean:
Sorry, I've messed up with relevant sentence. I meant not 10'000 classes (that'll be too extreme of a subsystem to rewrite in one go), but tens of thousand lines (spread over hundred or so small classes in dozen of files).
Your C code has 10000 structures instead of classes.
Not even close. It has couple of structures - but these are only used for testing. Production code just passes data around using regular variables (on registers if you use -O2). This means that a lot of things are just impossible to do without major refactoring/rewriting of the code (because the data is just not available where you need/want to have it), but why is that such a big deal? As long as the API is internal to this piece of code it's not a problem... and when you want to present API to the "outside world" you often want/need C API anyway...
to post comments)