this post was submitted on 25 Jan 2024
24 points (80.0% liked)

C Programming Language

998 readers
1 users here now

Welcome to the C community!

C is quirky, flawed, and an enormous success.
... When I read commentary about suggestions for where C should go, I often think back and give thanks that it wasn't developed under the advice of a worldwide crowd.
... The only way to learn a new programming language is by writing programs in it.

Β© Dennis Ritchie

🌐 https://en.cppreference.com/w/c

founded 1 year ago
MODERATORS
24
Ode to C (self.c_lang)
submitted 10 months ago by modev to c/c_lang
 

Personally, I have nothing against the emergence of new programming languages. This is cool:

  • the industry does not stand still
  • competition allows existing languages to develop and borrow features from new ones
  • developers have the opportunity to learn new things while avoiding burnout
  • there is a choice for beginners
  • there is a choice for specific tasks

But why do most people dislike the C language so much? But it remains the fastest among high-level languages. Who benefits from C being suppressed and attempts being made to replace him? I think there is only one answer - companies. Not developers. Developers are already reproducing the opinion imposed on them by the market. Under the influence of hype and the opinions of others, they form the idea that C is a useless language. And most importantly, oh my god, he's unsafe. Memory usage. But you as a programmer are (and must be) responsible for the code you write, not a language. And the one way not to do bugs - not doing them.

Personally, I also like the Nim language. Its performance is comparable to C, but its syntax and elegance are more modern.

And in general, I’m not against new languages, it’s a matter of taste. But when you learn a language, write in it for a while, and then realize that you are burning out 10 times faster than before, you realize the cost of memory safety.

This is that cost:

you are viewing a single comment's thread
view the rest of the comments
[–] sus 3 points 10 months ago (2 children)

another language that seems to get close to "C replacement" is Odin. Though it also does feel like departing a bit too much sometimes to be a true replacement.

And what every new language seems to be dead set on is no implicit type conversions which is mildly annoying (But I suppose that's done specifically to protect from gremlins like me)

[–] oscar 1 points 10 months ago (1 children)

The creator of Odin has stated that it is not aiming to replace C. It's its own thing. I suppose it has some degree of overlap, but I don't know the language well enough to speak on the differences. One thing I have read is that it does not support embedded devices very well.

He said this in the comments of a youtube interview:

GingerBill on replaing C

[–] sus 2 points 10 months ago

I think my idea of "C replacement" probably fits fairly closely with Odin's creator's idea of "C alternative"..

It's of course impossible to truly replace C with anything since C is an extremely entrenched language what with it being widely used for about 50 years. (and odin probably won't fit every niche where C is used)