Steve Klabnik changelog.com/posts

Today is a big day for Rust

Lots of great stuff in the Rust world today.

Rust 0.6

First of all, Rust 0.6.0 has been released! You can find the announcement here.

As always, Rust works on Mac, Windows, and Linux. To get it, do this:

$ wget http://static.rust-lang.org/dist/rust-0.6.tar.gz
$ $ shasum -a 256 rust-0.6.tar.gz
e11cb529a1e20f27d99033181a9e0e131817136b46d2742f0fa1afa1210053e5  rust-0.6.tar.gz
$ tar xvf rust-0.6.tar.gz
$ rust-0.6
$ ./configure
$ make
# make install

I added the SHA in there so you can verify you got everything properly. Now, compiling Rust is still pretty slow: it took about an hour on my MacBook Air.

I also have a pull request in on Homebrew, so after that’s merged, you should be able to use homebrew instead of mucking about on the command line.

What's new

So what’s new in Rust 0.6? You can find a detailed list of changes here, and the commit list here. There were 2,398 commits by 17 authors, damn!

While we cannot promise that this is the last time there will be incompatible changes, the great majority of anticipated language-level changes are complete in this version. We expect subsequent releases before a beta and final 1.0 to be more focused on non-language-level work (performance, libraries, packaging and building, runtime system) with only modest language-level changes as we discover bugs and areas requiring residual polish (primarily in the trait system, macro system, and borrow check).

This is the biggest thing for me. The language is almost completely settled down. You can find the meta-bug which describes all of the things that have yet to be removed here.

Here’s some of my favorite changes from the release:

  • Trailing sigils on closure types such as fn@, fn~ and fn& were removed in favour of the more-consistent leading sigils @fn, ~fn and &fn. (More consistent syntax is always good)
  • The move keyword was removed; owned types are always passed and assigned by moving now. (It was sorta odd that move was needed in places where the compiler could just infer it. This removes a bunch of clutter in code that sent owned types into spawned tasks, for example.)
  • The fail and assert keywords were replaced with macros fail!() and assert!(). (I'm generally pro-remove keywords, add macros)
  • in all cases mutability is controlled by mutability of the owner (inherited mutability). (Read this section in more depth, but I think this really helps the visibility of the mutability rules for a struct).
  • impl Ty : Trait { -> impl Ty for Trait {. (pretty!)
  • the "main function" doesn't need to be called main anymore, you can use #[main] to change it.
  • Rust now supports using inline assembly through the asm! macro. (WEBSCALE!!!!111lolz)

Neat stuff!

Mozilla + Samsung

Mozilla put out a press release today called “Mozilla and Samsung Collaborate on Next Generation Web Browser Engine”.

Translation? Servo is a real project now. At least, that’s how I read it.

We are now pleased to announce with Samsung that together we are bringing both the Rust programming language and Servo, the experimental web browser engine, to Android and ARM. This is an exciting step in the evolution of both projects that will allow us to start deeper research with Servo on mobile.

n the coming year, we are racing to complete the first major revision of Rust – cleaning up, expanding and documenting the libraries, building out our tools to improve the user experience, and beefing up performance. At the same time, we will be putting more resources into Servo, trying to prove that we can build a fast web browser with pervasive parallelism, and in a safe, fun language.

Cool! If you’re not aware, Servo is a massively parallel browser rendering engine, written in Rust. I haven’t been covering it here on the Changelog because it’s been a purely research project, but I’m really excited to see it move forward.


Discussion

Sign in or Join to comment or subscribe

Player art
  0:00 / 0:00