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
Official
Newsletters
Project/Tooling Updates
- Rust-Analyzer Changelog #120
- Tantivy 0.17 is out | Quickwit
- Knurling-rs changelog #34
- Fornjot (Code-CAD in Rust) - Weekly Dev Log - 2022-W10
- Slint Version 0.2.1 released -- weekly update
- Arti 0.1.0 is released: Your somewhat-stable API is here!
- Dioxus v0.2 Release: TUI, Router, Fermi, and Tooling
- This week in Databend #33: A Modern Cloud Data Warehouse for Everyone
Observations/Thoughts
- Introducing Rustler Precompiled - Dashbit Blog
- Announcing Savage, a computer algebra system written in Rust
- Oxide at Home: Propolis says Hello
- Things I hate about Rust, redux
- Async IO with completion-model IO systems
- Transcript: What's New in Rust 1.58 and 1.59
- [video] Rust Gamedev Meetup #14: March 2022
- [video] Rust fuzzing using cargo-libafl (LibAFL-based fuzzer) - Rust Security #4
- [audio] Interview with Fish Fight | Rust Game Dev
- [audio] PancakeDB with Martin Loncaric :: Rustacean Station
Rust Walkthroughs
- An In-Depth Introduction To Idempotency | A learning journal
- A Rust Gem: The Rust Map API
- RPATH, or why lld doesn’t work on NixOS
- Rust WebAssembly OCR experiments
Miscellaneous
- AUTOSAR announces WG for Rust in automotive
- [audio] Nick Cameron on Juggling Open Source Work and Parenthood
- [audio] Devtools podcast: building a new terminal in Rust
Crate of the Week
This week's crate is noline, a small no-std compatible readline-like line editor.
A lack of suggestions notwithstanding, llogiq is pretty pleased with his choice.
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.
Boa
If you are a Rust project owner and are looking for contributors, please submit tasks here.
Updates from the Rust Project
302 pull requests were merged in the last week
- diagnostics: do not spuriously claim something is "not an iterator"
- diagnostics: single colon within
<>
probably, not type ascription - improve suggestion when casting
usize
to (possibly) wide pointer - warn users about
||
inlet
chain expressions - suggest
if let
/let_else
for refutable pat inlet
- suggest using double colon when a struct field type include single colon
- miri: implement
simd_
{shuffle
,gather
,scatter
} - CTFE/Miri: detect out-of-bounds pointers in
offset_from
- change several
HashMap
s toIndexMap
to improve incremental hashing performance - improve
AdtDef
interning - optimize
ascii::escape_default
- make some
Clone
implsconst
- remove argument from closure in
thread::Scope::spawn
- use
MaybeUninit
inVecDeque
to remove the undefined behavior of slice - constify
Index
{,Mut
} for[T]
,str
, and[T; N]
- fix soundness issue in scoped threads
- implement
BITS
constant for non-zero integers - implement
MIN
/MAX
constants for non-zero integers - add
Result::
{ok
,err
,and
,or
,unwrap_or
} asconst
- add
Atomic
*::get_mut_slice
- add
core::hint::must_use
- unix: reduce the size of
DirEntry
- portable-simd: add
.min
and.max
for integers - compiler-builtins: add support for Apple watchOS
- futures: add
Mutex::lock_owned
andMutex::try_lock_owned
- rustfmt: improve mod resolution error for mods with multiple candidate files
- clippy: improve styles of filtering options for Clippy's lint list
- clippy: new lint that detects useless match expression
- clippy: new lint:
only_used_in_recursion
- clippy: allow
single_component_path_imports
for all macros - clippy: make
search_is_some
s suggestionMachineApplicable
Rust Compiler Performance Triage
Largely a quiet week. The perf improvement highlight is the use of real world crates such as syn
, cargo
, and serde
in the collecting of profile guided optimization (PGO) profiles. Previously only libcore
was used. This led to some decent improvement in compilation of real world crates (upwards of 5.5%).
On the regression side, the regressions were all largely small but contained inside of rollups making them hard to diagnose and correct. The perf team continues to work on process improvements that make changes to the compiler land through CI quickly while minimizing perf regressions that can sneak through.
Triage done by @rylev. Revision range: 10dccdc..3ba1eb
2 Regressions, 3 Improvements, 3 Mixed; 3 of them in rollups 42 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 RFCs entered Final Comment Period this week.
Tracking Issues & PRs
- [disposition: merge] Tracking Issue for JoinHandle::is_finished
- [disposition: merge] Tracking issue for const extern fn and const unsafe extern fn
- [disposition: merge] Always evaluate all cfg predicate in all() and any()
New and Updated RFCs
Upcoming Events
Rusty Events between 2022-03-16 - 2022-04-13 🦀
Virtual
- 2022-03-16 | Egg Harbor City, NJ, US | Neighborhood Math Club
- 2022-03-16 | Seattle, WA, US | Seattle Rust Meetup
- 2022-03-16 | Vancouver, BC, CA | Vancouver Rust
- 2022-03-16 | Wien, AT | Mob-Programming on Open Source Software
- 2022-03-17 | Stuttgart, DE | Rust Community Stuttgart
- 2022-03-23 | Egg Harbor City, NJ, US | Neighborhood Math Club
- 2022-03-24 | Charlottesville, VA, US | Charlottesville Rust Meetup
- 2022-03-24 | Linz, AU | Rust Linz
- 2022-03-29 | Berlin, DE | Berline
- 2022-03-29 | Dallas, TX, US | Dallas Rust
- 2022-03-30 | México City, MX | Rust MX
- 2022-04-05 | Beijing, CN | WebAssembly and Rust Meetup (Rustlang)
- 2022-04-05 | Buffalo, NY, US | Buffalo Rust Meetup
- 2022-04-05 | Denver, CO, US | Rust Denver
- 2022-04-06 | Egg Harbor City, NJ, US | Neighborhood Math Club
- 2022-04-06 | Indianapolis, IN, US | Indy Rust
- 2022-04-07 | Nürnberg, DE | Rust Nuremberg
- 2022-04-12 | Dallas, TX, US | Dallas Rust
- 2022-04-12 | Seattle, WA, US | Seattle Rust Meetup
- 2022-04-13 | Boulder, CO | Boulder Elixir and Rust
- 2022-04-13 | Egg Harbor City, NJ, US | Neighborhood Math Club
- 2022-04-13 | Munich, DE | Rust Munich
Europe
- 2022-03-17 | Edinburgh, UK | Rust Edinburgh
- 2022-04-12 | Berlin, DE | Rust Berlin
- 2022-04-13 | Munich, DE | Rust Munich
North America
- 2022-04-05 | Denver, CO, US | Rust Denver
- 2022-04-13 | Atlanta, GA, US | Rust ATL
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
Juspay
Komodo
Stockly
- Back-end developer - TechOps (Rust, gRPC, PostgreSQL) (Paris, FR)
- Back-end developer - Engine (Rust, gRPC, PostgreSQL) (Paris, FR)
Kollider
Tempus Ex
Tweet us at @ThisWeekInRust to get your job offers listed here!
Quote of the Week
protip: the rust extern keyword has a --help flag
``text error[E0703]: invalid ABI: found
--help` --> ext.rs:1:8 | 1 | extern "--help" {} fn main() {} | ^^^^^^^^ invalid ABI | = help: valid ABIs: Rust, C, C-unwind, cdecl, stdcall, stdcall-unwind, fastcall, vectorcall, thiscall, thiscall-unwind, aapcs, win64, sysv64, ptx-kernel, msp430-interrupt, x86-interrupt, amdgpu-kernel, efiapi, avr-interrupt, avr-non-blocking-interrupt, C-cmse-nonsecure-call, wasm, system, system-unwind, rust-intrinsic, rust-call, platform-intrinsic, unadjustederror: aborting due to previous error
For more information about this error, try
rustc --explain E0703
. ```
– Aria the Cat (with some help from rustc) on twitter
Thanks to Jacob Pratt for the 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