Hello and welcome to another issue of This Week in Rust! Rust is a systems language pursuing the trifecta: safety, concurrency, and speed. This is a weekly summary of its progress and community. Want something mentioned? Tweet us at @ThisWeekInRust or send us a pull request. Want to get involved? We love contributions.
This Week in Rust is openly developed on GitHub. If you find any errors in this week's issue, please submit a PR.
Updates from Rust Community
News & Blog Posts
- 2017 State of Rust Survey.
- The Rust Libz Blitz. Raising a solid core of the Rust crate ecosystem to a consistent level of completeness and quality as part of Rust language 2017 ergonomic improvements initiative.
- David Tolnay (of Serde fame) joins the Rust libs team.
- How I broke Rust's package manager for all Windows users.
- The pain of real linear types in Rust.
- The balance between cost, usability, and soundness in C bindings, and Rust-SDL2's release.
- gnome-class: Integrating Rust and the GNOME object system.
- Fearless concurrency in your microcontroller.
- Rust on Teensy part 3: Improving safety. PJRC Teensy is a USB-based microcontroller development system.
- Ownership controls mutability.
- Gtk-rs: New crates.io versions available and API improvements.
- Rust makes it into a AAA video game!... Sort of.
- This week in Rust docs 55.
- This week in Servo 101.
Crate of the Week
This week's crate of the week is remove_dir_all, a safe, reliable implementation of remove_dir_all
for Windows. Thanks to brson for the suggestion.
Submit your suggestions and votes for next week!
Call for Participation
Always wanted to contribute to open-source projects but didn't know where to start? Every week we highlight some tasks from the Rust community for you to pick and get started!
Some of these tasks may also have mentors available, visit the task page for more information.
- Crate evaluation for 2017-05-16: log. People are needed to help fill out the log crate evaluation, write cookbook recipes for the log crate, and generally offer their opinions.
- cross: OpenSSL missing for i686-musl. cross allows you to do "zero setup" cross compilation and "cross testing" of Rust crates.
- cross: libmusl with static OpenSSL.
- [easy] url: Implement Debug for many types. Servo's
url
is a URL parser library for Rust. - url: Implement
Default
forParseOptions
andParseOptions::new
. - [easy] url: Modify docs to put error conditions into
Errors
sections. - url: Better documentation for quirks module.
- [easy] url: Improvements to
Origin
docs. - [easy] url: Add examples to
Url
methods. - [easy] url: Add examples to
ParseOptions
. - url: Modify
define_encode_set
to support private definitions. - url: Document the percent_encoding module.
- [easy] rust-cookbook: Switch error handling setup to quick_main! macro from error-chain. Rust Cookbook is a collection of simple examples that demonstrate good practices to accomplish common programming tasks.
- memmap: Overhaul API. memmap-rs is a Rust library for cross-platform memory-mapped file IO.
- memmap: Document error conditions for fallible methods in a separate "Errors" section.
- memmap: Add examples to methods.
- memmap: Expand crate-level documentation.
- [easy] tokei: AutoHotKey support. Tokei is a program that displays statistics about your code.
If you are a Rust project owner and are looking for contributors, please submit tasks here.
Updates from Rust Core
122 pull requests were merged in the last week.
MutexGuard<T>
is now onlySync
ifT
is (breaking change, fixes unsoundness)- far-ranging MIR pipeline changes (also adds "stealing" as a more violent form of borrowing)
- fix arm-linux-androideabi
- fix Windows' ULONG_PTR type on Windows 32 bit systems
- Rust documenters can now write '
##
' to show#
in rustdoc output - Windows doctests no longer deadlock
- reworking
NonZero
,Shared
andUnique
(so they can be stabilized – fingers crossed) core::sync::atomic::hint_core_should_pause()
for optimized atomic spin loops- various LLVM backports
- variance refactoring, no more
pub
map - on-demand-ify region mapping
- remove ast-ty-to-ty cache
- delete no longer used
syntax
features - remove unused
TyCtxt
fields - suggest
!
for bitwise negation when encountering~
prefix (ease transition from C) - point to fields that make type recursive
- lint against and remove anonymous parameters (deprecated soon)
- remove obsolete
--disable-elf-tls
switch - forbid
-Z
on stable and beta - the rust build process can now generate XZ-compressed tarballs
- rust-installer will use available
xz
or7z
cargo bench --all
New Contributors
- acdenisSK
- Bobby Holley
- Charlie Sheridan
- Jing Zhao
- Joshua Sheard
- Masaki Hara
- Migi
- Raphaël Huchet
- Tommy Ip
Approved RFCs
Changes to Rust follow the Rust RFC (request for comments) process. These are the RFCs that were approved for implementation this week:
No RFCs were approved this week.
Final Comment Period
Every week the team announces the 'final comment period' for RFCs and key PRs which are reaching a decision. Express your opinions now. This week's FCPs are:
- [disposition: close] Allow any Displayable type for expect.
- [disposition: merge] Expand and stabilize
impl Trait
. - [disposition: merge] Specify
#[repr(transparent)]
. - [disposition: merge] Extend entry API to work on borrowed keys.
- [disposition: merge] Remove static bound from type_id.
- [disposition: merge] extend
?
to operate over other types.
New RFCs
Result::pass()
, turningResult<T,E>
intoResult<U,F>
, ifFrom
is set up.- Opaque Data structs for FFI.
- Add external doc attribute to rustc.
- Match branch semicolon.
Style RFCs
Style RFCs are part of the process for deciding on style guidelines for the Rust community and defaults for Rustfmt. The process is similar to the RFC process, but we try to reach rough consensus on issues (including a final comment period) before progressing to PRs. Just like the RFC process, all users are welcome to comment and submit RFCs. If you want to help decide what Rust code should look like, come get involved!
We're making good progress and the style is coming together. If you want to see the style in practice, check out our example or use the Integer32 Playground and select 'Proposed RFC' from the 'Format' menu. Be aware that implementation is work in progress.
PRs:
Issues in final comment period:
- Ordering of types of groups within a module
- Struct and tuple literals
- Array literals
- Where clauses
- Imports (
use
)
Good first issues:
We're happy to mentor these, please reach out to us in #rust-style if you'd like to get involved
Other interesting issues:
Upcoming Events
- May 10. Rust Rome - Rust Meetup #2 - Intro + Rocket.rs.
- May 10. Rust Community Team Meeting at #rust-community on irc.mozilla.org.
- May 10. Rust Documentation Team Meeting at #rust-docs on irc.mozilla.org.
- May 11. Columbus Rust Society - Monthly Meeting.
- May 11. Rust DC - Building high performance REST APIs with Rust and Rocket.
- May 13. Mozilla Philippines - Introduction to Rust (Programming Language).
- May 15. Rust Sydney Meetup - Happy Birthday Rust!
- May 16. Tokyo Rust Meetup #7 - Rust Birthday Party!
- May 16. Rust Paris Meetup #37.
- May 16. 1st Cambridge Rust Meetup.
- May 17. Rust LA May Meetup - Rust Birthday Party!
- May 17. South Florida Rust - Rust Birthday Party!
- May 17. Rust Atlanta - Heterogeneous Collections in Rust at Tech Square Labs (Midtown).
- May 17. OpenTechSchool Berlin - Rust Hack and Learn.
- May 17. Rust Community Team Meeting at #rust-community on irc.mozilla.org.
- May 17. Rust Documentation Team Meeting at #rust-docs on irc.mozilla.org.
- May 18. Rust release triage.
- May 20. Rust Bangalore community meetup.
- May 24. Rust Community Team Meeting at #rust-community on irc.mozilla.org.
- May 24. Rust Documentation Team Meeting at #rust-docs on irc.mozilla.org.
If you are running a Rust event please add it to the calendar to get it mentioned here. Email the Rust Community Team for access.
Rust Jobs
No jobs listed for this week.
Tweet us at @ThisWeekInRust to get your job offers listed here!
Quote of the Week
The answer is obvious: it's the intersection of trust and frustration.
— /u/kibwen answering - What does Rust mean?.
Thanks to Jean for the suggestion.