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
- November project goals update
- This Development-cycle in Cargo: 1.84
- December 2024 Project Director Update
Newsletters
Project/Tooling Updates
- hyper Roadmap 2025
- Bevy Fallible Systems, Bindless, and Immutable Components
- Sequoia PGP: A Sapling Matures: Meet sq 1.0
- Release 0.30.0 - egui_kittest and modals
- fish-shell 4.0b1, now in Rust
- Introducing Limbo: A complete rewrite of SQLite in Rust
- Streaming data analytics, Fluvio 0.14.0 release
- Announcing Hex Display: A modern
xxd
alternative - Diesel: Window functions
- Rerun 0.21.0 - Graph view, 3D Grid & UI/UX improvements
- Introducing Fjädra — a Rust port of
d3-force
for graph layouts
Observations/Thoughts
- What are temporal and spatial memory safety?
- Reducing WASM binary size
- Crash recovery in 256 bytes
- Rust crate feature debugging
- [audio] Building Rust: An interview with Nell Shamrell-Harrington
Rust Walkthroughs
- Read the Code: Using Drop Safely in Rust
- Thoughts on Rust hashing
- Scheme to the Spec Part I: Concurrent Cycle Collection
- Solving Advent of Code at Compile Time with Rust Macros
- [video] Rust code reading: The thousands crate
- [video] Building a Lua package manager in Rust (Arabic)
Miscellaneous
- What is shift-left ⬅️ programming?
- Rust social status update 2024.12
- So many tokens, so little time: Introducing a faster, more flexible byte-pair tokenizer
Crate of the Week
This week's crate is cmd_lib, a library of command-line macros and utilities to write shell-script like tasks easily in Rust.
Thanks to Remo Senekowitsch 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. The following RFCs would benefit from user testing before moving forward:
RFCs
Rust
Rustup
If you are a feature implementer and would like your RFC to appear on the above list, add the new 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.
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!
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.
No Calls for papers or presentations were submitted this week.
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!
Updates from the Rust Project
437 pull requests were merged in the last week
- (Re-)Implement
impl_trait_in_bindings
rustc_borrowck
: Stop suggesting the invalid syntax&mut raw const
rustc_mir_dataflow
cleanups, including some renamingsrustc_target
: ppc64 target string fixes for LLVM 20- add AST support for unsafe binders
- add unpolished, experimental support for AFIDT (async fn in dyn trait)
- allow
symbol_intern_string_literal
lint in test modules - arbitrary self types v2: main compiler changes
- change
GetManyMutError
to match T-libs-api decision - check for array lengths that aren't actually
usize
- codegen
#[naked]
functions using global asm - correctly handle comments in attributes in doctests source code
- don't ICE when encountering never in range pattern
- don't make a def id for
impl_trait_in_bindings
- don't show the full linker args unless
--verbose
is passed - don't use
AsyncFnOnce::CallOnceFuture
bounds for signature deduction - encode coroutine-closures in SMIR
- exercise const trait interaction with default fields
- fix ICE on type error in promoted
- fix ICE when multiple supertrait substitutions need assoc but only one is provided
- fix
trimmed_def_paths
ICE in the function ptr comparison lint - fix our
llvm::Bool
typedef to be signed, to matchLLVMBool
- interpret: reduce usage of
TypingEnv::fully_monomorphized
- jsondocck: parse, don't validate commands
- keep track of parse errors in
mod
s and don't emit resolve errors for paths involving them - lint on combining
#[no_mangle]
and#[export_name]
- make
Copy
unsafe to implement for ADTs withunsafe
fields - make sure to use normalized ty for unevaluated const in default
struct
value - modifies the index instruction from
gep [0 x %Type]
togep %Type
- properly consider APITs for never type fallback ascription fix
- remove
Lexer
's dependency onParser
- remove queries from the driver interface
- rudimentary heuristic to insert parentheses when needed for RPIT overcaptures lint
- some asm! diagnostic adjustments and a papercut fix
- some trait method vs impl method signature difference diagnostic cleanups
- suggest using deref in patterns
- suppress field expr with generics error message if it's a method
- try to evaluate constants in legacy mangling
- tweak multispan rendering to reduce output length
- use SourceMap to load debugger visualizer files
- use a more precise span in
placeholder_type_error_diag
- use newly added exceptions to non default branch warning
- validate
--skip
and--exclude
paths - validate self in host predicates correctly
- bounds-check with PtrMetadata instead of Len in MIR
- miri: TB Optimization: Skip subtrees based on the subtree's root node's permissions
- miri:
localtime_r
: deduplicate timezone name allocation - miri: use clap in miri-script
- stabilize
const_nonnull_new
- stabilize async closures (RFC #3668)
- stabilize the Rust 2024 prelude
UniqueRc
trait implsstd::net
: Solaris supportsSOCK_CLOEXEC
as well since 11.4- add value accessor methods to
Mutex
andRwLock
- de-duplicate and improve definition of
core::ffi::c_char
- run TLS destructors for wasm32-wasip1-threads
- wasi/fs: improve stopping condition for
<ReadDir
asIterator>::next
- codegen_gcc: stabilize
lang_tests_common
config parsing logic - codegen_gcc: use casts instead of bitcast between pointers and integers to fix issues when using the lld linker
- cargo: build-script: Pass
CARGO_CFG_FEATURE
- cargo: SourceId: use stable hash from rustc-stable-hash
- cargo: base: Support bases in patches in virtual manifests
- cargo: build-rs: Implicitly report rerun-if-env-changed for input
- cargo: resolver: Don't report all versions as rejected
- cargo: resolver: In errors, show rejected versions over alt versions
- cargo: resolver: Report invalid index entries
- cargo: resolver: Report unmatched versions, rather than saying no package
- cargo: script: Don't override the release profile
- cargo: a faster hash for ActivationsKey
- cargo: implement
--depth workspace
forcargo tree
command - cargo:
emit_serialized_unit_graph
uses the configured shell - rustdoc-search: fix mismatched path when parent re-exported twice
- rustdoc-search: handle
impl Into<X>
better - rustdoc: fix self cmp
- clippy: allow
needless_option_take
to report for more cases - clippy: better help message for
comparison_chain
lint - clippy: correct
single_match
lint suggestion - clippy: correct suggestion for
unnecessary_sort_by
inno_std
- clippy: correctly handle string indices in
literal_string_with_formatting_arg
- clippy: detect shadowing in pattern field
- clippy: do not suggest using
Error
inno_std
before Rust 1.81 - clippy: fix
must_use_unit
suggestion when there're multiple attributes - clippy: fix
single_match
lint being emitted when it should not - clippy: initial impl of
repr_packed_without_abi
- rust-analyzer: add an assist to extract an expression into a constant
- rust-analyzer: add diagnostic fix to remove unnecessary wrapper in type mismatch
- rust-analyzer: preserve order of parameters in
extract_functions
- rust-analyzer: report unresolved idents for implicit captures in
format_args!()
- rust-analyzer: fix publish workflow link in manual
- rust-analyzer: copied proc-macros not being cleaned up on exit
- rust-analyzer: fix a panic with a diagnostics fix when a keyword is used as a field
- rust-analyzer: fix path qualified auto-importing completions not working with re-exports
- rust-analyzer: fix proc-macro dylib names on windows
- rust-analyzer: fix sourceroot construction for virtual manifests
- rust-analyzer: generate implementation with items even if snippet text edit is disabled
- rust-analyzer: improve name suggestion for
destructure_tuple_binding
- rust-analyzer: panic when displaying generic params with defaults, again
- rust-analyzer: swallow rustfmt parsing panics
- rust-analyzer: use string literal contents as a name when extracting into variable
- rust-analyzer: hash completion items to properly match them during /resolve
- rust-analyzer: properly handle different defaults for severity of lints
- rust-analyzer: show expansion errors in
expand_macro
feature
Rust Compiler Performance Triage
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
Tracking Issues & PRs
Rust
Cargo
Language Team
Language Reference
Unsafe Code Guidelines
New and Updated RFCs
Upcoming Events
Rusty Events between 2024-12-18 - 2025-01-15 🦀
Virtual
- 2024-12-19 | Virtual | Scandio GmBH
- 2024-12-19 | Virtual (Berlin, DE) | OpenTechSchool Berlin + Rust Berlin
- 2024-12-19 | Virtual (Buenos Aires, AR) | Rust en Español
- 2024-12-19 | Virtual (Mexico City, DF, MX) | Rust MX
- 2024-12-20 | Virtual (Jersey City, NJ, US) | Jersey City Classy and Curious Coders Club Cooperative
- 2024-12-22 | Virtual (Tel Aviv-Yafo, IL) | Rust 🦀 TLV
- 2024-12-24 | Virtual (Dallas, TX, US) | Dallas Rust
- 2024-12-26 | Virtual (Charlottesville, VA, US) | Charlottesville Rust Meetup
- 2025-01-02| Virtual (Berlin, DE) | OpenTechSchool Berlin + Rust Berlin
- 2025-01-04 | Virtual (Kampala, UG) | Rust Circle Kampala
- 2025-01-06 | Virtual (Tel Aviv-Yafo, IL) | Code Mavens 🦀 - 🐍 - 🐪
- 2025-01-07 | Virtual (Tel Aviv-Yafo, IL) | Code Mavens 🦀 - 🐍 - 🐪
- 2025-01-08 | Virtual (Tel Aviv-Yafo, IL) | Code Mavens 🦀 - 🐍 - 🐪
- 2025-01-09 | Virtual (Charlottesville, VA, US) | Charlottesville Rust Meetup
- 2025-01-14 | Virtual (Dallas, TX, US) | Dallas Rust User Meetup
- 2025-01-14 | Virtual (Tel Aviv-Yafo, IL) | Code Mavens 🦀 - 🐍 - 🐪
- 2025-01-15 | Virtual (Vancouver, BC, CA) | Vancouver Rust
Asia
- 2025-01-12 | Virtual (Tel Aviv-Yafo, IL) | Rust 🦀 TLV
Europe
- 2024-12-18 | Ghent, BE | Systems Programming Ghent
- 2025-01-08 | Reading, UK | Reading Rust Workshop
- 2025-01-09 | Virtual (Nürnberg, DE) | Rust Nuremberg
- 2025-01-09 | Oslo, NO | Rust Oslo
North America
- 2024-12-22 | Boston, MA, US | Boston Rust Meetup
- 2024-12-26 | Mountain View, CA, US | Hacker Dojo
- 2025-01-10 | Boston, MA, US | Boston Rust 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
She said yes!! (And so did I!)
– Amos on Mastodon proving that Rustaceans do have a life outside of Rust. Congratulations, Amos!
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, bennyvasquez.
Email list hosting is sponsored by The Rust Foundation