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? Tag us at @ThisWeekInRust on X (formerly Twitter) or @ThisWeekinRust on mastodon.social, or send us a pull request. Want to get involved? We love contributions.
This Week in Rust is openly developed on GitHub and archives can be viewed at this-week-in-rust.org. If you find any errors in this week's issue, please submit a PR.
Want TWIR in your inbox? Subscribe here.
Updates from Rust Community
Official
- Announcing rustup 1.28.1
- Inferred const generic arguments: Call for Testing!
- This Month in Our Test Infra: January and February 2025
Project/Tooling Updates
- Native Git support in Zed - Zed Blog
- tfmcp 🦀: A Rust-Implemented Tool to Operate Terraform from LLMs
- What's new in SeaORM 1.1
Observations/Thoughts
- Rust in 2025: Targeting foundational software
- A Happy Day for Rust
- Rust Learning Resources 2025
- Taming A Voracious Rust Proxy
- Succinct data structures
- When is "this trait can be implemented" part of the trait's public API?
- When are Rust's const fns executed?
- Rust trait object layout
- The Art of Formatting Code
- [video] Rust is the New C
- [audio] Rust with Guillaume Gomez
Rust Walkthroughs
- Writing into uninitialized buffers in Rust
- Translating bzip2 with c2rust
- Nine Pico PIO Wats with Rust: Raspberry Pi programmable IO pitfalls illustrated with a musical example (Part 1)
- Async Rust for Dummies
- How we built our 2025 Embedded World Demos
- [video] Ratatui - terminal user interfaces in Rust with Orhun Parmaksız - build ratatop in pair programming
- [video] Derive Macros: Or, How I Learned to Stop Worrying and Love the proc_macro2::TokenStream
- [video] Porting the guff plot device to Rust
Miscellaneous
Crate of the Week
This week's crate is eval-macro, a crate that allows to evaluate macros at compile time, giving similar feel to Zig's comptime.
Thanks to Aleksander Krauze for the suggestion!
Please submit your suggestions and votes for next week!
Calls for Testing
An important step for RFC implementation is for people to experiment with the implementation and give feedback, especially before stabilization.
If you are a feature implementer
and would like your RFC to appear in this list, add a call-for-testing
label to your RFC along
with a comment providing testing instructions and/or guidance on which aspect(s) of the feature
need testing.
- No calls for testing were issued this week by Rust, Rust language RFCs or Rustup.
Let us know if you would like your feature to be tracked as a part of this list.
Call for Participation; projects and speakers
CFP - Projects
Always wanted to contribute to open-source projects but did not 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.
No Calls for participation were submitted this week.
If you are a Rust project owner and are looking for contributors, please submit tasks here or through a PR to TWiR or by reaching out on X (formerly Twitter) or Mastodon!
CFP - Events
Are you a new or experienced speaker looking for a place to share something cool? This section highlights events that are being planned and are accepting submissions to join their event as a speaker.
- GOSIM Rust Spotlight - Nominate and support your favorite projects! | Closes 2025-03-15 at 7:59am UTC | Utrecht, NL | 2025-05-13 - 2025-05-17
If you are an event organizer hoping to expand the reach of your event, please submit a link to the website through a PR to TWiR or by reaching out on X (formerly Twitter) or Mastodon!
Updates from the Rust Project
555 pull requests were merged in the last week
Compiler
- ergonomic ref counting
- on long spans, trim the middle of them to make them fit in the terminal width
- split the
Edges
iterator - perf: change TaskDeps to start preallocated with 128 capacity
- perf: speed up target feature computation
Library
- stabilize
[T]::split_off...
methods - stabilize
box_uninit_write
- stabilize
const_char_classify, const_sockaddr_setters
- stabilize
const_vec_string_slice
- stabilize
string_extend_from_within
- stabilize feature
const_copy_from_slice
- override default
Write
methods for cursor-like types - specialize
OsString::push
andOsString as From
for UTF-8 - perf: improve the generic MIR in the default
PartialOrd::le
and friends - count char width at most once in
Formatter::pad
- fix char count in
Display
forByteStr
- fix crash in
BufReader::peek()
Cargo
- cargo tree: Add
--depth public
behind-Zunstable-options
- cargo: add terminal integration via ANSI OSC 9;4 sequences
- cargo: don't use
$CARGO_BUILD_TARGET
incargo metadata
- cargo: add completions for add --path
- cargo: add completions for install --path
- cargo: respect --frozen everywhere --offline or --locked is accepted
Rustdoc
- fix
O(tests)
stack usage in edition 2024 mergeable doctests - search: increase strictness of typechecking* rustdoc: add attribute-related tests for rustdoc JSON
- hide item that is not marked as
doc(inline)
and whose src isdoc(hidden)
Clippy
- clippy:
arbitrary_source_item_ordering
: Make alphabetic ordering in module item groups optional - clippy:
unnecessary_to_owned
: don't calliter()
on a temporary object - clippy: add missing tests annotations for
ui-internal
- clippy: don't trigger
blocks_in_conditions
when the condition contains areturn
- clippy: don't trigger
unnecessary_debug_formatting
in tests - clippy: fix
manual_let_else
missing binding mode - clippy: better help for
mixed_case_hex_literals
- clippy: improve
needless_pass_by_value
suggestion - clippy: make
struct_field_names
check private fields of public structs - clippy: refactor function after adding a new diagnostic item
- clippy: remove Known problems section for
vec_box
- clippy: rename the MSRV alias
MANUAL_DIV_CEIL
toDIV_CEIL
- clippy: use
size_of
from the prelude instead of imported - clippy:
io_error_other
: walk back to the root context to compute the span
Rust-Analyzer
- rust-analyzer:
fix(hir): VariantDef
isimpl HasSource
- rust-analyzer: add missing name-ref parents to syntactic highlighting
- rust-analyzer: add warning and debug information when
cargo metadata
fails - rust-analyzer: adjust relevance scoring threshold to consistent with existing implem…
- rust-analyzer: add diagnostic for dangling dyn and impl
- rust-analyzer: warn the user when a rename will change the meaning of the program
- rust-analyzer:
path
macro hygiene - rust-analyzer: syntax highlightingg punct filtering ignoring mods
- rust-analyzer: fix diagnostics being cleared right after being received
- rust-analyzer: normalize projections in evaluated const display and layout calculation
- rust-analyzer: prevent wrong invocations of
needs_parens_in
with non-ancestral "parent"s - rust-analyzer: highlight unsafe operations as unsafe, not definitions
- rust-analyzer: improve keyword completion for 'let' and 'let mut'
- rust-analyzer: log build script error output in
load_cargo::load_workspace_at
- rust-analyzer: make
GenericParamsCollector::type_or_consts
not unnecessarilypub(crate)
- rust-analyzer: make change annotations per text-edit
- rust-analyzer: move loaded project MSRV back to 1.78, show notification for the warning
- rust-analyzer: rank ADT constructors as constructors for completion scoring
Rust Compiler Performance Triage
This week we had to merge a lot of large rollups due to many problems with our CI infrastructure, which made analysis harder. Even though the aggregated stats look like there were a lot of regressions, it is skewed by two large regressions happening on an uncommon optimized incremental build and a documentation build of a single crate. The documentation regression is being tracked, and fixes to some other regressions are already in progress.
Triage done by @kobzol. Revision range: daf59857..9fb94b32
Summary:
(instructions:u) | mean | range | count |
---|---|---|---|
Regressions ❌ (primary) |
1.2% | [0.2%, 58.8%] | 149 |
Regressions ❌ (secondary) |
4.2% | [0.2%, 165.8%] | 127 |
Improvements ✅ (primary) |
-1.1% | [-14.0%, -0.3%] | 31 |
Improvements ✅ (secondary) |
-2.9% | [-38.4%, -0.1%] | 43 |
All ❌✅ (primary) | 0.8% | [-14.0%, 58.8%] | 180 |
2 Regressions, 2 Improvements, 5 Mixed; 4 of them in rollups 37 artifact 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.
Tracking Issues & PRs
Rust
Rust RFCs
Other Areas
- No Items entered Final Comment Period this week for Cargo, Language Team, Language Reference or Unsafe Code Guidelines.
Let us know if you would like your PRs, Tracking Issues or RFCs to be tracked as a part of this list.
New and Updated RFCs
Upcoming Events
Rusty Events between 2025-03-12 - 2025-04-09 🦀
Virtual
- 2025-03-13 | Virtual (Berlin, DE) | Rust Berlin
- 2025-03-18 | Virtual (Tel Aviv-Yafo, IL) | Code Mavens 🦀 - 🐍 - 🐪
- 2025-03-18 | Virtual (Washington, DC, US) | Rust DC
- 2025-03-19 | Virtual (Vancouver, BC, CA) | Vancouver Rust
- 2025-03-20 | Virtual (Tel Aviv-Yafo, IL) | Code Mavens 🦀 - 🐍 - 🐪
- 2025-03-25 | Virtual (Dallas, TX, US) | Dallas Rust User Meetup
- 2025-03-25 | Virtual (London, UK) | Women in Rust
- 2025-03-27 | Virtual (Berlin, DE) | Rust Berlin
- 2025-04-01 | Virtual (Buffalo, NY, US) | Buffalo Rust Meetup
- 2025-04-02 | Virtual (Indianapolis, IN, US) | Indy Rust
- 2025-04-03 | Virtual (Nürnberg, DE) | Rust Nurnberg DE
- 2025-04-05 | Virtual | Ardan Labs
- 2025-04-08 | Virtual (Dallas, TX, US) | Dallas Rust User Meetup
Asia
- 2025-03-15 | Beijing, CN | WebAssembly and Rust Meetup (Wasm Empowering AI)
- 2025-03-19 | Tel Aviv-Yafo, IL | Rust 🦀 TLV
- 2025-03-28 | Kowloon Tong, HK | Rust Asia
- 2025-04-05 | Bangalore/Bengaluru, IN | Rust Bangalore
Europe
- 2025-03-12 | Reading, UK | Reading Rust Workshop
- 2025-03-13 | Biel, CH | Rust Bern
- 2025-03-14 | Paris, FR | Rust in Paris
- 2025-03-18 | Basel, CH | Rust Basel
- 2025-03-18 | Leipzig, DE | Rust - Modern Systems Programming in Leipzig
- 2025-03-20 | Edinburgh, UK | Rust and Friends
- 2025-03-20 | Prague, CZ | Rust Prague
- 2025-03-25 | Aarhus, DK | Rust Aarhus
- 2025-03-25 | Eindhoven, NL | RustNL
- 2025-03-25 | London, UK | London Rust Project Group
- 2025-03-26 | Frankfurt, DE | Rust Rhein-Main
- 2025-03-26 | Manchester, UK | Rust Manchester
- 2025-03-26 | Warsaw, PL | Rustikon
- 2025-03-27 | Augsburg, DE | Rust Meetup Augsburg
- 2025-04-02 | München, DE | Rust Munich
- 2025-04-02 | Oxford, UK | Oxford Rust Meetup Group
- 2025-04-02 | Stockholm, SE | Stockholm Rust
- 2025-04-03 | Oslo, NO | Rust Oslo
- 2025-04-08 | Olomouc, CZ | Rust Moravia
- 2025-04-09 | Reading, UK | Reading Rust Workshop
North America
- 2025-03-13 | Chicago, IL, US | Chicago Rust Meetup
- 2025-03-13 | Portland, OR, US | PDXRust
- 2025-03-18 | San Francisco, CA, US | San Francisco Rust Study Group
- 2025-03-18 | Spokane, WA, US | Spokane Rust
- 2025-03-20 | Mountain View, CA, US | Hacker Dojo
- 2025-03-20 | Nashville, TN, US | Music City Rust Developers
- 2025-03-20 | Redmond, WA, US | Seattle Rust User Group
- 2025-03-21 | México City, MX | Rust MX
- 2025-03-26 | Austin, TX, US | Rust ATX
- 2025-03-27 | Atlanta, GA, US | Rust Atlanta
- 2025-03-31 | Boulder, CO, US | Solid State Depot
- 2025-04-03 | Montréal, QC, CA | Rust Montréal
- 2025-04-03 | Saint Louis, MO, US | STL Rust
South America
- 2025-03-15 | São Paulo, BR | Rust São Paulo Meetup
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.
Jobs
Please see the latest Who's Hiring thread on r/rust
Quote of the Week
Treat anything starting with
cargo
as if it iscargo run
. This applies even to commands that do not build anything, such ascargo clean
, and third-party plugins, such ascargo audit
.
– Sergey "Shnatsel" Davidoff on /r/rust
Thanks to llogiq for the suggestion!
Please submit quotes and vote for next week!
This Week in Rust is edited by: nellshamrell, llogiq, cdmistman, ericseppanen, extrawurst, U007D, joelmarcey, mariannegoldin, bennyvasquez, bdillo
Email list hosting is sponsored by The Rust Foundation