Hello and welcome to another issue of This Week in Rust! Rust is a programming language empowering everyone to build reliable and efficient software. 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
Project/Tooling Updates
- Hello, youki! (low-level container runtime written in Rust)
- Nushell 0.42
- This Year in Wgpu - 2021
- SixtyFPS (GUI crate): 2021 in Review
- BonsaiDb December Update: Finishing up alpha 1
- NAPI-RS 2.0 released
- This Year in Embedded Rust: 2021 Edition
- Rust Analyzer Changelog #108
- End of year 2021: 20 months of Gitoxide
- This week in Databend #22: an elastic and reliable cloud warehouse
Research
Observations/Thoughts
- Thoughts on Context and Capabilities in Rust
- My negative views on Rust
- Learning Rust – Why now?
- [audio] What's New in Rust 1.56 and 1.57
- [audio] Code Like a Pro in Rust with Brenden Matthews
Rust Walkthroughs
- Vange-rs: WebAssembly in Rust
- Writing a minimal Lua implementation with a virtual machine from scratch in Rust
- Bringing Rust to Space - Setting up a Rust ecosystem for the VA108XX MCU family
- Scala and Rust interoperability via JNI
- Writing a prometheus exporter in rust from idea to grafana chart
- Futuristic Rust: context emulation
- Mocking HTTP Services in Rust
- LLVM Infrastructure and Rust
- Making Games in Rust - Part 6 - Generating a Map
- Procedural Macros: Parsing custom syntax
- A Data Pipeline for Go Trains Delay Analysis — ML in Action with Rust
- [video] Tetris in Rust from scratch
- [video] Rust Modules - Explained Like I'm 5
- [video] I'm learning Rust - Enums, patterns, and traits
- [FR] [video] Parlons peu, parlons Rust!
- [ZH] Rust性能评估与调优实践
Crate of the Week
This week's crate is zoxide, a smarter cd
command.
Thanks to Ajeet D'Souza for the self-suggestion!
Please 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.
If you are a Rust project owner and are looking for contributors, please submit tasks here.
Updates from the Rust Project
188 pull requests were merged in the last week
- miri: provide slightly better notes when tracking a pointer tag
- backport LLVM changes to disable deferred inlining
- fix duplicate derive clone suggestion
- perf: change
Backtrace::enabled
atomic fromSeqCst
toRelaxed
- perf: eliminate
ObligationCauseData
- fix bad caching of
~const Drop
bounds - constify
core::intrinsics::black_box
andcore::hint::black_box
- make
PTR::as_ref
and similar methodsconst
- RawVec: don't recompute capacity after allocating
- allow reverse iteration of lowercase'd/uppercase'd chars
- stabilise
entry_insert
- suggest adding
#[cfg(test)]
to a test module - cargo: make levenshtein distance case insensitive.
- clippy: add suggestion for
neg_multiply
lint - clippy: fix
iter_skip_next
false positives - clippy: improve
unwrap_or_else_default
when handlingunwrap_or_else(XXX::new)
- clippy: fix
shadow_reuse
false negative for if let bindings - clippy: fix an ICE on unwrapping a None
- clippy: new lint:
init-numbered-fields
- rustfmt: fix static async closure qualifier order
- rustfmt: retain qualified path when rewriting struct literal expressions
Rust Compiler Performance Triage
Relatively quiet week, mostly rustdoc improvements.
Triage done by @simulacrum. Revision range: 3d57c61a..e91ad5fc62
2 Regressions, 1 Improvements, 6 Mixed; 0 of them in rollups
26 comparisons made in total
Approved RFCs
Changes to Rust follow the Rust RFC (request for comments) process. These are the RFCs that were approved for implementation 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.
RFCs
- No new RFCs entered Final Comment Period this week.
Tracking Issues & PRs
- [disposition: merge] Clarify the guarantees that ThreadId does and doesn't make.
- [disposition: merge] Remove effect of
#[no_link]
attribute on name resolution - [disposition: merge] Tracking Issue for Stdin::lines, Stdin::split forwarder methods
- [disposition: merge] Tracking issue for Result::cloned, Result::cloned_err, Result::copied, Result::copied_err
- [disposition: merge] Remove unnecessary bounds for some Hash{Map,Set} methods
New RFCs
- No new RFCs were published this week.
Upcoming Events
Rusty Events between 12/29/2021 - 1/31/2022 🦀
Online
- January 5, 2022 | Indianapolis, IN, US | Indy.rs - with Social Distancing | Indy Rust
- January 6, 2022 | Cardiff, UK | Rust Book Study Session - Automated Tests & Building a Command Line Program | Rust and C++ Cardiff
- January 6, 2022 | Nürnberg, DE | Rust Nürnberg online #8| Rust Nuremberg
- January 8, 2022 | Various cities | Rust GameDev Monthly Meetup | Rust GameDev
- January 11, 2022 | Dallas, TX, US | Second Tuesday Meetup| Dallas Rust
- January 11, 2022 | Seattle, WA, US | Monthly meetup | Seattle Rust Meetup
- January 12, 2022 | Boulder, CO, US | Monthly Meetup | Boulder Elixir and Rust
- January 12, 2022 | Los Angeles, CA, US | Live Coding Session - Mob Programming a Rust Code Kata [Virtual] Jan. 2022 | Rust Los Angeles
- January 12, 2022 | Stuttgart, DE | Rust-Meetup | Rust Community Stuttgart
- January 13, 2022 | Warsaw, PL | Rust Warsaw #4 | Rust Warsaw
- January 18, 2022 | Washington, DC, US| Mid-month Rustful | Rust DC
- January 19, 2022 | Vancouver, BC, CA | Rust Study/Hack/Hang-out night |Vancouver Rust
- January 25, 2022 | Dallas, TX, US | Last Tuesday Meetup | Dallas Rust
North America
- January 6, 2022 | Austin, TX, US | Rust Lunch | Rust ATX
- January 12, 2022 | Atlanta, GA, US | Grab a beer with fellow Rustaceans | Rust Atlanta
- January 13, 2022 | Columbus, OH, US | Monthly Meeting | Columbus Rust Society
If you are running a Rust event please add it to the calendar to get it mentioned here. Please remember to add a link to the event too. Email the Rust Community Team for access.
Rust Jobs
The Daily Edit
Spruce
- Software Engineer, Backend (New York, NY, US or Remote)
- Engineering Manager (New York, NY, US or Remote)
Parity Technologies
- Rust Core Engineer - Solidity Compiler (Solang)
- Core Runtime Engineer - Substrate
- Multiple other Rust / Blockchain Engineering positions
Tweet us at @ThisWeekInRust to get your job offers listed here!
Quote of the Week
One reason we keep certain things as hard errors rather than lints: it establishes a baseline that you can safely assume about other people's code, since it can't be turned off. And as a result, that baseline can become part of people's mental model of Rust itself, rather than something that might or might not be true in any given codebase.
We have to take care to not use that lightly, because that places work on all users of Rust to maintain code to that baseline. But there are cases where we do. We don't allow using one integer type where another was expected. We don't allow certain operations outside an unsafe block. ...
I think the standard we should apply is asking whether something is part of the baseline that people should be able to assume about all Rust code, and if that's worth the tradeoff of requiring that baseline of all Rust users.
– Josh Triplett on rust-internals
Thanks to Josh Triplett for the self-suggestion!
Please submit quotes and vote for next week!
This Week in Rust is edited by: nellshamrell, llogiq, cdmistman, ericseppanen, extrawurst, andrewpollack, U007D, kolharsam, joelmarcey, mariannegoldin.
Email list hosting is sponsored by The Rust Foundation