Live data from Hacker News

Integrating “safe” languages into OpenBSD?

marc.info

291–300 of 344 posts

Re: Integrating “safe” languages into OpenBSD?

#291

Earlier quoted context omitted.

There are those of us who have been writing C++ for decades and are sick of the footguns and build systems but have never had a viable alternative before. I don't think anyone is arguing that we should throw everything out, however for all my greenfield stuff Rust has been a welcome breath of fresh air. Yeah, there are some people who are a little too over the top but a large part of the support behind Rust is from t…

(well I mean there has been Ada* for ages) *or fortran or pascal

[deleted]

Re: Integrating “safe” languages into OpenBSD?

#292

I remember I stopped frequenting /r/programming when it became this weird Haskell echo chamber. It was a bubble where a small but vocal faction inside the community seemed to over react to any criticism. They methodically and tirelessly responded to every comment with an endless litany of "facts" showing how Haskell could do anything from os kernels to game programming. They touted every industry mention of Haskell u…

It's become clear to me that a lot of the Rust fanatics don't actually know how C++ works and and Rust is their first low-level language. The ones I'm talking about know enough to make them sound like they know what they're talking about unless you actually know what they're trying and failing to accurately describe. It sounds and seems like a language worthy of more investigation on my part, but I have to agree that…

>It's become clear to me that a lot of the Rust fanatics don't actually know how C++ works and and Rust is their first low-level language.

Why would not knowing C++ bar people from anything? It's a wildly specific skill, diminishing in importance every day.

Re: Integrating “safe” languages into OpenBSD?

#293
post #173

I remember I stopped frequenting /r/programming when it became this weird Haskell echo chamber. It was a bubble where a small but vocal faction inside the community seemed to over react to any criticism. They methodically and tirelessly responded to every comment with an endless litany of "facts" showing how Haskell could do anything from os kernels to game programming. They touted every industry mention of Haskell u…

There is a sort of social game that seems to emerge at some point, combining the worst of in-group bullshit and logic-puzzlng as a substitute for actually attempting to help folks honestly seeking questions. The game goes like this: start discussing something: say, including rust in OpenBSD. - Assume it (here, using rust in oBSD) is a great idea. - For each objection, explain why it is trivial. Your tools are your ow…

> After getting a series of jackass responses to a simple question

Getting those responses where, exactly?

If you had mentioned literally any other language with a FLOSS community around it I wouldn't question that statement. However, Rust proponents so clearly claim to do the opposite-- you've even got Steve below explicitly stating that jackassery isn't allowed in Rust forums.

What's the data to the contrary?

Re: Integrating “safe” languages into OpenBSD?

#294

Earlier quoted context omitted.

There are those of us who have been writing C++ for decades and are sick of the footguns and build systems but have never had a viable alternative before. I don't think anyone is arguing that we should throw everything out, however for all my greenfield stuff Rust has been a welcome breath of fresh air. Yeah, there are some people who are a little too over the top but a large part of the support behind Rust is from t…

> I don't think anyone is arguing that we should throw everything out, however for all my greenfield stuff Rust has been a welcome breath of fresh air. If you can write things from scratch in a clear room fashion, perhaps. C++ is very good, when you need to integrate a lot of 'low-level' libraries (that are alredy in C or C++) together in a meaninful way, like for instance, browsers do. Like the capacity to 'talk' wi…

> And by the way, modern C++ is already secure enough, making some selling points for Rust, a little bit of cosmetic right now.

There is not a single large-scale network-facing widely attacked piece of software I'm aware of in C++ that has not fallen to some memory safety problem. Memory safety issues frequently produce RCE.

Re: Integrating “safe” languages into OpenBSD?

#295

I remember I stopped frequenting /r/programming when it became this weird Haskell echo chamber. It was a bubble where a small but vocal faction inside the community seemed to over react to any criticism. They methodically and tirelessly responded to every comment with an endless litany of "facts" showing how Haskell could do anything from os kernels to game programming. They touted every industry mention of Haskell u…

It's become clear to me that a lot of the Rust fanatics don't actually know how C++ works and and Rust is their first low-level language. The ones I'm talking about know enough to make them sound like they know what they're talking about unless you actually know what they're trying and failing to accurately describe. It sounds and seems like a language worthy of more investigation on my part, but I have to agree that…

> It's become clear to me that a lot of the Rust fanatics don't actually know how C++ works and and Rust is their first low-level language.

That doesn't change the fact that Rust programs are, when memory safety is concerned, more secure than C++ programs. This is true both in theory and in practice.

Re: Integrating “safe” languages into OpenBSD?

#296
post #268

Earlier quoted context omitted.

The real problem is when it's not just binding: it's actually using metaprogramming, which is a huge part of why I use C++. There's no equivalent to blaze or eigen for linear algebra in Rust, and much of that heavy lifting is handled by templates. (There are some libraries with rudimental expression template-like behavior, but nothing as sophisticated.)

This is the sort of thing that bothers me about these kinds of arguments. Sure, you're always going to be able to find certain domains where existing libraries or language features make a certain ecosystem very well suited. And that's fine. No one's saying to discard the best tool for the job for another one that might have some general advantages but won't actually get you where you need to go. But there are a ton o…

Perfect. I absolutely agree. The thing is, I use C++ because it does a lot of things specialized for what I need. I don't work on every problem, and I look forward to the chance to use Rust. That being said, for now, the problems I'm working on are domains that very much benefit from C++ and I will continue to use it.

I totally agree that Rust is a great language and has wide applications. It doesn't fit my current needs, but I don't doubt it meets many people's needs. More power to them -- and it's cool to have a "The new C++ killer language" which can actually live up to its hype, unlike Java and C# and Go and D.

Re: Integrating “safe” languages into OpenBSD?

#297
post #268

Earlier quoted context omitted.

This is the sort of thing that bothers me about these kinds of arguments. Sure, you're always going to be able to find certain domains where existing libraries or language features make a certain ecosystem very well suited. And that's fine. No one's saying to discard the best tool for the job for another one that might have some general advantages but won't actually get you where you need to go. But there are a ton o…

Perfect. I absolutely agree. The thing is, I use C++ because it does a lot of things specialized for what I need. I don't work on every problem, and I look forward to the chance to use Rust. That being said, for now, the problems I'm working on are domains that very much benefit from C++ and I will continue to use it. I totally agree that Rust is a great language and has wide applications. It doesn't fit my current n…

What's wrong with D? I quite liked it when I used it (for a relatively small project). It's not really a C++ replacement (GC), but as a high-level language the only problem I found was lack of a large library ecosytem - the language itself was quite pleasant to work with (more so than C++ and even Rust, which I also like).

Re: Integrating “safe” languages into OpenBSD?

#298

Earlier quoted context omitted.

There are those of us who have been writing C++ for decades and are sick of the footguns and build systems but have never had a viable alternative before. I don't think anyone is arguing that we should throw everything out, however for all my greenfield stuff Rust has been a welcome breath of fresh air. Yeah, there are some people who are a little too over the top but a large part of the support behind Rust is from t…

> I don't think anyone is arguing that we should throw everything out, however for all my greenfield stuff Rust has been a welcome breath of fresh air. If you can write things from scratch in a clear room fashion, perhaps. C++ is very good, when you need to integrate a lot of 'low-level' libraries (that are alredy in C or C++) together in a meaninful way, like for instance, browsers do. Like the capacity to 'talk' wi…

>modern C++ is already secure enough

Why to have nullptr dereferencing? Why to have an undefined behavior on option dereferencing? Why to have dangling refs? Why not to check borrow possibility statically? God, we don't event have a decent and safe variant (sum) type in c++. Adding all that (unnecessary) complexity c++ has (how many whatever-values and initializations does it have?). It is unsafe as hell, and lots of stuff could be made safer trivially in a new language (say, rust or F*).

Re: Integrating “safe” languages into OpenBSD?

#299

Earlier quoted context omitted.

> I don't think anyone is arguing that we should throw everything out, however for all my greenfield stuff Rust has been a welcome breath of fresh air. If you can write things from scratch in a clear room fashion, perhaps. C++ is very good, when you need to integrate a lot of 'low-level' libraries (that are alredy in C or C++) together in a meaninful way, like for instance, browsers do. Like the capacity to 'talk' wi…

>modern C++ is already secure enough Why to have nullptr dereferencing? Why to have an undefined behavior on option dereferencing? Why to have dangling refs? Why not to check borrow possibility statically? God, we don't event have a decent and safe variant (sum) type in c++. Adding all that (unnecessary) complexity c++ has (how many whatever-values and initializations does it have?). It is unsafe as hell, and lots of…

Just as a sidenote, rust has no defined behaviour when dereferencing a null pointer. What makes it worse is that a null pointer in an option is handled as None instead of Some, which kind of broke some of my code until I found that particularly nasty bug and worked around it (with offsets).

Re: Integrating “safe” languages into OpenBSD?

#300

Earlier quoted context omitted.

> then points out that rustc can't compile itself on i386, which is relevant… how? I'm actually gobsmacked this is the case. There used to be a saying, only half-joking, that a language that can't host/compile/bootstrap itself is nothing more than a toy. As others have more eloquently pointed out, it shouldn't have to be explained why people who write operating systems and compilers would consider that a no-go.

Eh, 64-bit desktops were becoming common a decade ago. Considering the small minority of developers using a 32-bit machine for development, I don't see that it is worthwhile to spend effort on that. Note that Rust can (and does) target various 32-bit platforms (ARM and maybe RISC-V, not sure) for cross-compile. Self-hosting on a 32-bit platform is such a minor drawback these days. 64-bit ARM processors are becoming m…

There are still plenty of 32bit machines out there. I personally have maintained and support a Intel 4004 knockoff used for controlling a big industrial machine. And of course more modern variants of the same machine with an 8008. Some of these couldn't even run DOS but it's still supported.

32bit is not even close to be being that old and lots of machines, applications or platforms require it and they need maintenance. Especially OpenBSD is a system that I as a Linux-fan recognize for supporting old hardware much better than Linux.

And it's not only 32bit x86, there is plenty of other architectures limited to 32bit, mostly from the ARM sector but I believe some older MIPS and other even more exotic arch's are supported.

If rust can't selfhost on x86 how can we expect it to selfhost on more exotic 32bit hardware that BSD supports?

Post reply on HN