Live data from Hacker News

"No way to prevent this" say users of only language where this regularly happens

xeiaso.net

211–220 of 342 posts

Re: "No way to prevent this" say users of only language where this regularly happens

#211

Earlier quoted context omitted.

Maybe it is but the last several years of periodic (and quite embarrassing) CVEs suggest otherwise.

What they suggest? What I and the discussed article claim is that safe code isn't written because programmers don't want it. CVEs aren't caused by desires, they are caused by unsafe code.

Many people suggest to start gradually migrating to either Rust or start investing much more seriously in formally proving C/C++ code (which is IMO a huge endeavor).

As I said in multiple other comments, I know there are valid cases for C/C++ where various factors prevent migration. I am not playing a little rebel revolutionary here, I am addressing the people who can migrate away but refuse to do so based on hand-wavy philosophy clashes (or my favorite petty rebellious take: "people praise Rust, I must resist using it!"). Petty stuff and I am pretty disappointed that people who bill themselves as "engineers" refuse to see objective evidence and hold on to only what they know.

Those are the people I address with my comment. Not the people who will be never allowed to migrate away a 2 million lines worth of C codebase. They have my deepest sympathies.

Re: "No way to prevent this" say users of only language where this regularly happens

#212
post #86

Earlier quoted context omitted.

No I'm not. I expected that there is some furry or anime girl visible when i click on that link. This is the stuff i do not want to have on my screen when there are coworkers nearby.

Have this: https://xeiaso.net/notes/2024/ai-hype/

I also used to think I had this issue when reading your blogs at work. Turns out, nobody really cares and if they do, a quick explanation suffices entirely. I no longer care as well.

Your imagery is part of who you are as a writer, and it's part of your work. People need to take it or leave it.

Re: "No way to prevent this" say users of only language where this regularly happens

#213
post #182

Earlier quoted context omitted.

[flagged]

Well, I'm glad that you volunteered to go live in Soviet Russia or Fascist Germany, or a disarmed Native American tribe. Disarming population leads to tyranny without consequences.

[deleted]

Re: "No way to prevent this" say users of only language where this regularly happens

#214

Earlier quoted context omitted.

Mostly agreed with your comment though I still have to remark that every community has zealots and it's mystifying to me why are people so annoyed by Rust's. So it's hard to agree that "Rust is a cult". As you said, it's a pragmatic but also kinda niche language. I don't reach for it unless I can't do the job with others, easier and quicker to work with languages.

The C sphere is actually refreshingly free of zealotry (mainly I guess because there isn't such a thing as a "C community" and even despite C being the main attack target of language zealots - funny enough nobody complains about those pesky assembly coders and their hippie attitude towards memory safety lol). The "religious zeal" was also an important reason why I switched back to C from C++ and why I don't have much…

> This was an important reason why I switched back to C from C++ and why I don't have much interest in Rust. I can't quite stand the the "holier than thou" attitude in.parts of those communities.

This is 100% baffling to me. Let me explain.

1. Every single area has zealots. Yours included. And we're not talking only work. Every hobby area as well.

2. What the attitude of the most toxic 0.1% of the users of a thing is has exactly ZERO correlation with whether the thing is good and worth using.

3. By resisting only those 0.1% toxic zealots you are only demonstrating meaningless rebelliousness. As a supposed adult you should be immune to what are people hyping up and form your own opinion. INFORMED opinion. Not one based on the "many people praise it hence I, the intellectual, will stay far away from that obvious nonsense" stance.

4. Have you considered that maybe, just maybe, Rust is praised because it's actually good? Have you considered that the Rust community is not trying to cheat its way into your heart, and that the love Rust gets is justified by the people who need its features? Seems like you did not, and that's disappointing.

In other words, I have zero clue of your thought process here, maybe you can help me understand?

Back in my home town the VW Golf had an ardent fan base, yet one of my friends still bought one after he graduated. He didn't call the people who loved VW Golf zealots. He did his research and concluded that with his budget and mechanic skills the VW Golf is the ideal option.

Food for thought?

Re: "No way to prevent this" say users of only language where this regularly happens

#215

Earlier quoted context omitted.

The right questions according to who? Are your coreutils replacements 100% drop-in?

I don't need a 100% drop-in. Barely anyone does. I've observed at least 80% of all of the coreutils features are not used by 90% - 99% of programmers and sysadmins. Ask people if they used all flags of `sort` and report back results as a test of my hypothesis. > The right questions according to who? This is tiring. I told you twice that I'd prefer you engaging in technical merits. You keep drawing attention to what i…

But the only "technical merit" seems to be "omg it's more secure". I've literally never seen any other argument in favor of Rust.

Re: "No way to prevent this" say users of only language where this regularly happens

#216

Earlier quoted context omitted.

This isn't a crazy thought to have about K&R C. They're trying to fit a high level language onto a 1970s computer and so sacrifices must be made. Some of the trades they make are... questionable and others I'd say clearly wrong (they just don't need Tony's billion dollar mistake, nor to be so cavalier with types in general), but it's not as though they're targeting a machine with gigabytes of RAM and a multi-core CPU…

What things simplicity do you lose? I think there isn't much of a difference between these dialects. Most important one might be possibility to define variables on the spot instead of at top of block. Then, some people like C99 compound literals. I don't think any of these break simplicity, they are quality-of-life improvements with no interactions with the rest of the language semantics. Next one is what, the C11 me…

Here's my thinking. It's fair to say C99 isn't that much more complicated than C89, which formalizes various things that are a bad idea such as "volatile", as well as numerous good ideas like hey we should let you define a variable where you use the variable - however C99 adds more of the bad like "restrict".

In both those cases the K&R C model was very simple. You could decide you love how simple this model is, and when smarter compilers optimise it into a pretzel or other languages are faster that's OK. This code used to drive the serial port, now it does nothing, OK, don't use C to write such drivers. This code used to go real fast, now everybody else is faster, OK, don't use C if you need the best performance.

C89 and C99 choose different, making the language more complicated to keep addressing performance and compatibility. In C99 I can write the fast serial port driver, but it's significantly more complicated as a result. The beginner will definitely get it wrong and explaining why is pretty subtle.

Then C11 says actually you're not writing sequential programs, which was a crucial simplification in K&R C - the programs you can write do one thing at a time, in order, and then maybe stop. The memory model in C11 is needed because it says actually your programs might do more or different things at once.

Now, in reality by 2011 lots of people were writing C that's not actually sequential - after all SMP Linux long pre-dates C11. But those weren't legal C programs, they're GNU's dialect and so all bets are off. Nobody is claiming Linux is simple.

So C11 definitely isn't the simple language for a 1970s computer any more. C11 is a competitor with C++ or today Rust. And it doesn't fare so well by that comparison.

Re: "No way to prevent this" say users of only language where this regularly happens

#217

Earlier quoted context omitted.

The C sphere is actually refreshingly free of zealotry (mainly I guess because there isn't such a thing as a "C community" and even despite C being the main attack target of language zealots - funny enough nobody complains about those pesky assembly coders and their hippie attitude towards memory safety lol). The "religious zeal" was also an important reason why I switched back to C from C++ and why I don't have much…

> This was an important reason why I switched back to C from C++ and why I don't have much interest in Rust. I can't quite stand the the "holier than thou" attitude in.parts of those communities. This is 100% baffling to me. Let me explain. 1. Every single area has zealots. Yours included. And we're not talking only work. Every hobby area as well. 2. What the attitude of the most toxic 0.1% of the users of a thing is…

In Europe (esp Eastern), if you take resale price into account you have to get a german car because everything else loses value faster :)

The VWs you can just dump on the fans.

I know, I live in a similar country.

Re: "No way to prevent this" say users of only language where this regularly happens

#218

Earlier quoted context omitted.

The C sphere is actually refreshingly free of zealotry (mainly I guess because there isn't such a thing as a "C community" and even despite C being the main attack target of language zealots - funny enough nobody complains about those pesky assembly coders and their hippie attitude towards memory safety lol). The "religious zeal" was also an important reason why I switched back to C from C++ and why I don't have much…

> This was an important reason why I switched back to C from C++ and why I don't have much interest in Rust. I can't quite stand the the "holier than thou" attitude in.parts of those communities. This is 100% baffling to me. Let me explain. 1. Every single area has zealots. Yours included. And we're not talking only work. Every hobby area as well. 2. What the attitude of the most toxic 0.1% of the users of a thing is…

I spent 20 years with C++ as my main language, and the endless and heated "style discussions" where personal.opinions are thrown around like facts were just tiring and a massive waste of time.

And it's such endless circular discussion where the extremists show up (I guess the equivalent in Rust is shaming projects that use unsafe, IIRC there have been quite a few dramas in the past). Shit like this is simply mentally exhausting, and in now 7 years of C as my main language I did not encounter this even once). In general C coders seems to be a quite relaxed, happy and tolerant bunch.

Re: "No way to prevent this" say users of only language where this regularly happens

#219

Earlier quoted context omitted.

> This was an important reason why I switched back to C from C++ and why I don't have much interest in Rust. I can't quite stand the the "holier than thou" attitude in.parts of those communities. This is 100% baffling to me. Let me explain. 1. Every single area has zealots. Yours included. And we're not talking only work. Every hobby area as well. 2. What the attitude of the most toxic 0.1% of the users of a thing is…

I spent 20 years with C++ as my main language, and the endless and heated "style discussions" where personal.opinions are thrown around like facts were just tiring and a massive waste of time. And it's such endless circular discussion where the extremists show up (I guess the equivalent in Rust is shaming projects that use unsafe, IIRC there have been quite a few dramas in the past). Shit like this is simply mentally…

Restating your anecdotal evidence is just stubborn and does not advance any discussion but you do you.

You also addressed almost zero of what I said and asked you.

Re: "No way to prevent this" say users of only language where this regularly happens

#220
post #71
post #22

More broadly: > "No way to prevent $THIS" say users of only language where $THIS regularly happens A weird psychological quirk I've noticed (of myself, and others) is we'll often exhibit a sort of 'programming language xenophobia', where we apathetically accept (or don't even notice) unpleasantries of our language of choice, yet be quite averse to the unpleasantries of other languages. Maybe it's due to sunk cost; ti…

I would rather have unpleasantries that make the language safer vs unpleasantries that make it more vulnerable. Especially when the unpleasantries in question don’t even make the language easier to use.

C standard: "Undefined behavior means such a situation can't happen."

Me: "If it can't happen then it would be fine to just crash on those situations, right? Because such a crash would never be reached. Can we get that?"

C compilers: "No. Would you want to crash on signed integer overflow, for example?"

Me: "Yes? Would be safer than the current situation at least."

C compilers: "What, no, that would make your programs imperceptibly slower. Would you even like that?"

Me: "Yes, I'll be able to live with that."

C compilers: "Well, the answer is still no."

Post reply on HN