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
- Pathfinder, a fast GPU-based font rasterizer in Rust.
- A simple Rust GUI with QML.
- How copying an int made my code 11 times faster.
- Graphical depiction of ownership and borrowing in Rust.
- Rust Generic (not Generics). Write functions that abstract over types and arity, but still have the ability to recover your original type afterwards.
- How librsvg exports reference-counted objects from Rust to C.
- Writing an interpreter in Rust. A weekly series on writing a toy interpreter in Rust.
- Rust tutorial: authz. Learn Rust-specific concepts using a real-world application.
- Rust sucks if I fail to write X.
- Diesel 0.11 released with MySQL support.
- Fireplace is a modular Wayland window manager written in Rust.
- This week in Rust docs 44.
- This week in Ruma 2017-02-19.
- What's coming up in imag 23.
Crate of the Week
This week's crate of the week is CDRS, a client for Apache Cassandra written completely in Rust. Thanks to Alex Pikalov 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.
- [easy] rust:
std::ffi::FromBytesWithNulError
is not anstd::error::Error
. - [easy] clippy: Lint functions taking references as arguments but only use them to create an owned value.
- [easy] clippy: Lint for iterating over a slice with one (or zero) element.
- [easy] clippy: useless_transmute being raised when it's doing multiple casts.
- [easy] clippy: Lint to suggest
.saturating_add/sub(x)
for.checked_add/sub(x).unwrap_or(MAX/MIN)
. - [easy] clippy: Lint against const atomics.
- [easy] crates.io: Insufficient spacing between Dev-Dependencies and Versions.
- [easy] crates.io: Document applying categories/adding new categories.
- [medium] crates.io: Yanking a crate should update its max_version.
- [medium] crates.io: Exact match not being obvious.
- [medium] crates.io: Be able to search within a keyword or category.
If you are a Rust project owner and are looking for contributors, please submit tasks here.
Updates from Rust Core
107 pull requests were merged in the last week.
- stabilize Field-init shorthand (RFC #1682)
- ignore expected types in diverging blocks
- make derive macro passes independent
- improved derive macro suggestions
- fix macro sequence repetition ICE
- fix segfault on disordered BTrees
Hash
{Map
,Set
}::retain(_)
- adaptive
HashMap
TypeId
now implements (Partial
)Ord
- more
Cell
methods for non-Copy
types Cell::swap(..)
is_ascii_...(_)
- conversions between various string types
TraitSelect
now with lessVec
- MIR:
SwitchInt
all the branches! - fix two ICEs in path resolution
- erase late-bound regions in
get_vtable_methods
- port books to mdbook (bye bye rustbook)
New Contributors
- Amos Onn
- Andrew Gaspar
- Benoît CORTIER
- Brian Vincent
- Dmitry Guzeev
- Glyne J. Gittens
- Jeff Muizelaar
- Luxko
- Matt Williams
- Michal Nazarewicz
- Mikhail Pak
- Sebastian Waisbrot
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: merge] extend
?
to operate over other types. - [disposition: merge] Write to standard error with
eprint!
andeprintln!
. - [disposition: close] Add a
Transmute<T>
trait for representing types that can be transmuted toT
. - [disposition: merge] Deprecate anonymous parameters.
- [disposition: close] Warn by default when encountering a statement which only consists of an equality comparison.
- Allow uncallable method impls to be omitted.
New RFCs
- Reverting default unsafety. Provide ability to mark unsafe-by-default entities, like foreign items, as safe.
- Unsized Rvalues. Allow for local variables, function arguments, and some expressions to have an unsized type.
- Add a
#[safe("Reason")]
to annotate why unsafe blocks are actually safe. - Macros 1.2: Fast-track to stabilize function-like procedural macros. Stabilize function-like procedural macros (whose usage looks like
foo!(...)
), like this was done in “Macros 1.1” for customderive
, before “Macros 2.0” is fully ready. - Extend and stabilize the
FixedSizeArray
trait, as a stop-gap solution for integer parameters in generics. - Unsafe lifetime. Add a new special lifetime,
'unsafe
, that implicitly satisfies any constraint, but may only be instantiated within an unsafe context.
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!
PRs:
Issues in final comment period:
Other significant issues:
Upcoming Events
- Feb 22. Rust Community Team Meeting at #rust-community on irc.mozilla.org.
- Feb 22. Rust Documentation Team Meeting at #rust-docs on irc.mozilla.org.
- Feb 22. OpenTechSchool Berlin - Rust Hack and Learn.
- Feb 23. Rust release triage.
- Feb 23. Rust Dresden.
- Feb 23. Rust Copenhagen: Hack Night
- Feb 24. Crate Polishing Workshop, Darmstadt/Germany.
- Mar 1. Rust User Group Cologne - Web development in Rust.
- Mar 1. South Florida Rust - Intro to Ownership and Borrowing.
- Mar 1. Rust Community Team Meeting at #rust-community on irc.mozilla.org.
- Mar 1. Rust Documentation Team Meeting at #rust-docs on irc.mozilla.org.
- Mar 7. Rust Oslo - What's New - Focus on web services.
- Mar 8. Rust Community Team Meeting at #rust-community on irc.mozilla.org.
- Mar 8. Rust Documentation Team Meeting at #rust-docs on irc.mozilla.org.
- Mar 9. Columbus Rust Society - Monthly Meeting.
- Mar 9. Rust release triage.
- Mar 29. GNOME+Rust Hackfest 2017, Mexico City.
- Mar 31. Underhanded Rust Contest Submission Deadline
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
- Full Stack Developer for Resin Supervisor (JavaScript + Rust).
- Postdoc positions for RustBelt project at MPI-SWS.
Tweet us at @ThisWeekInRust to get your job offers listed here!
Quote of the Week
No quote was selected for QotW.