Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Why C sucks

Name: Anonymous 2009-08-20 11:53

Shitty,slow and bug-prone string functions. NULL termination and strlen are shining examples of defective design.

No memory management, plenty of things going down the drain if
you don't watch them all. Malloc and free are slow and inefficient, and they ruin performance if used in fast loops.

Variadic functions: all C has is shitty macro which doesn't implement anything useful. C cannot determine types of such variadiac arguments at runtime. Everything is static.

Typeof(non-standard)/sizeof/pointer casts in many programs show how defective the implementation of only object C manages(the pointer) natively. Pointers(and arrays which are also pointers) are the glue of C, yet they lack anything useful(like size or datatype,sizeof alternatives like _msize/malloc_usable_size and typeof are ugly non-standard hacks)  and people use void pointers for felxibility.

Name: Anonymous 2009-08-20 22:27

Python and Perl are far, far too slow. Lisp and the other functional languages are even slower, and have no library
support; they are essentially toy languages.

Lisp, slow? A lot of implementations are natively compiled and are damn fast if you do your own benchmarks. If your specific app is too slow, just profile your code and add some type declarations or rewrite your code in a more efficient manner. You get the choice how fast your code will run. You don't get the choice to write your programs in a clean manner in C, you have to write all that management code first.

No library support? Last I checked, there's plenty of good libraries, and even if they're not that many, you have excellent FFI support, so you can just reuse libraries written in other languages if you need to.

Toy languages? It's used in the industry for some demanding applications, but they are by no means popular languages. I think a language's popularity is irrelevant, just use what solves your problem best. If you turn to some framework for a few ready-made solutions, you're just limiting yourself to whatever they offer.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List