News for hackers. Stuff that matters.
Re:Writing an OS in Rust: Handling Exceptions by Sir_Cmpwn on Sunday March 26, 2017 @12:23PM (#13961509)
Previously: https://hn.algolia.com/?q=phil-opp.com

Just about every page of this tutorial has frontpaged on HN. I guess people really, really, really want more kernels written in Rust!

Re:Writing an OS in Rust: Handling Exceptions by kibwen on Sunday March 26, 2017 @01:31PM (#13961888)
I don't think Phil's goal is to produce a Rust-based kernel so much as it is to demonstrate some of the nitty-gritty details of how kernels work, while also just happening to use Rust (which provides an opportunity to discuss how many of those gnarly unsafe bits can be encapsulated behind safe interfaces, while others can't).
Re:Writing an OS in Rust: Handling Exceptions by jeffdavis on Sunday March 26, 2017 @12:36PM (#13961593)
It's a way to learn about OSes and rust at the same time. It's also high-quality content.
Re:Writing an OS in Rust: Handling Exceptions by pcwalton on Sunday March 26, 2017 @09:32PM (#13964474)
Or maybe these tutorials are some of the best tutorials on low-level operating system design in any language.

I've certainly learned a lot from them.

Re:Writing an OS in Rust: Handling Exceptions by glangdale on Sunday March 26, 2017 @05:39PM (#13963458)
Is it a surprise? Rust claims to be a systems language - and what better proof of that than someone writing a kernel in it? To me this is a clear example of "doing what it says on the tin". Also, I view the fact that the code is startlingly readable and seems (to my untutored eyes) to look a lot like other Rust code as a pretty strong validation that they are delivering on their promise.
Re:Writing an OS in Rust: Handling Exceptions by milesrout on Monday March 27, 2017 @04:13PM (#13971286)
No surprise that you get responses from the Rust Defence League.

They downvote any criticisms of Rust here and on reddit, and upvote anything that mentions it in a positive light. They rush to its defence everywhere.

I seriously reckon that steveklabnik and pcwalton must have a bot watching HN and reddit for mentions of Rust so they can immediately rush to its defence every time it comes up.

It's a pity because I actually think the language has potential, but it's not going to be successful if they're incapable of taking any critique on board. And it's not ready, it's not mature. They have to accept that.

Re:Writing an OS in Rust: Handling Exceptions by wtetzner on Monday April 03, 2017 @02:38PM (#14025701)
> And it's not ready, it's not mature. They have to accept that.

Do you have anything specific in mind that makes it "not ready"? And when you say it's not ready, what isn't it ready for?

Re:Writing an OS in Rust: Handling Exceptions by adamnemecek on Sunday March 26, 2017 @12:32PM (#13961563)
> I guess people really, really, really want more kernels written in Rust!

Anyone who doesn't either doesn't kernel much or has Stockholm syndrome and is in denial.

Re:Writing an OS in Rust: Handling Exceptions by Sir_Cmpwn on Sunday March 26, 2017 @12:35PM (#13961589)
"I must be right because anyone who disagrees with me is ignorant or insane"
Re:Writing an OS in Rust: Handling Exceptions by adamnemecek on Sunday March 26, 2017 @12:42PM (#13961620)
Can you point out to me a single criticism of Rust that isn't "it's too immature" or a variation thereof (e.g. less code written in it)?
Re:Writing an OS in Rust: Handling Exceptions by nickpsecurity on Sunday March 26, 2017 @01:09PM (#13961767)
That "it's too immature" is a great, dismissal line given it's incredibly important for choosing a language to write a safe/secure kernel in. My choice against it as main language would be due to lack of assurance technology made for it. With C subset and/or SPARK Ada, I have a pile of tech from formal specifications to static analysis to test generators to assembly certifiers. Add powerful IDE's & ecosystem to it. Then, even if people don't want that, there's regular compilers for what I produce on countless platforms for increased usage opportunities and extra security through hardware diversity/obfuscation. Rust doesn't give me all this. Not just "immature:" nobody working on most of it at all or with enough effort I know it will be there in 1-3 years when I need it.

That said, I love and encourage your work on Redox plus these other Rust-based kernels. There's no reason to gripe about them that I see. The posts are good for learning like most kernel dev w/ extra language & safety content on the side. You Redox devs in particular are really rolling on it being safe & practically usable. There's just that the gap between what's achievable on high end with Rust and C/SPARK is the size of the grand canyon. Many PhD's worth of work.

Re:Writing an OS in Rust: Handling Exceptions by Sir_Cmpwn on Sunday March 26, 2017 @12:45PM (#13961639)
I don't necessarily disagree with you, just with the way you present your point.
Re:Writing an OS in Rust: Handling Exceptions by frozenport on Monday March 27, 2017 @04:39AM (#13966039)
Re:Writing an OS in Rust: Handling Exceptions by jeffdavis on Sunday March 26, 2017 @01:12PM (#13961783)
How about "it's too immature to properly criticize"?

;-)

Re:Writing an OS in Rust: Handling Exceptions by kibwen on Sunday March 26, 2017 @01:37PM (#13961915)
What are your criteria for maturity? I tend to agree that Rust has a ways to go before it's capable of calling itself a world-class implementation, but lots of those aspects (e.g. IDE support) are on this year's roadmap and seeing active development.
Re:Writing an OS in Rust: Handling Exceptions by steveklabnik on Sunday March 26, 2017 @02:23PM (#13962220)
Here's a good one in which Rust isn't yet mature enough in this space: this still requires nightly.
Re:Writing an OS in Rust: Handling Exceptions by jeffdavis on Sunday March 26, 2017 @06:25PM (#13963695)
My comment was not entirely sincere; I'm very optimistic about rust's future.

The grain of truth is that, if you grant that rust is immature, then it's unfair to say that's the only criticism because a lot of problems can be hidden behind immaturity.