<a href="https://os.phil-opp.com/news/2018-03-09-pure-rust/" rel="nofollow">https://os.phil-opp.com/news/2018-03-09-pure-rust/</a> provides a lot more context here.<p>I am <i>extremely</i> excited by this work. One of the hardest parts of hacking on a hobby OS is the environment. My own project has been hampered for nearly a year because I switched to Windows and couldn’t get the tooling working. (A combination of my lack of Windows knowledge and a lack of desire to spend random Saturdays figuring out obscure toolchain issues.) And that’s with rustc already being a cross compiler.<p>This now means that, with Rust, getting going on any platform Rust supports is now trivial. It’s quite exciting.
What a great book!<p>I had a question about the section "A Freestanding Rust Binary" specifically the the "start attribute" section. The author states:<p>"The ! return type means that the function is diverging, i.e. not allowed to ever return. This is required because the entry point is not called by any function, but invoked directly by the operating system or bootloader. So instead of returning, the entry point should e.g. invoke the exit system call of the operating system."<p>Is this explicitly "diverging" marking a Rust specific bit of housekeeping?
For instance I wasn't aware of any parallel in the C runtime but maybe someone could shed some light on this?
I've seen a series of these types of articles, and I'm not sure if they're trying to make the next linux or doing it for fun.<p>One problem to me is drivers, drivers, drivers. Linux has a bunch of 'em. Other operating systems, not so much.
That was interesting. I found the headstands necessary to write to a raw address a bit taxing. In C you'd just use the `volatile` keyword. But being able to localize unsafe code is a big win.