Title: This Week in Rust 386
Number: 386
Date: 2021-04-14
Category: This Week in Rust

Hello and welcome to another issue of *This Week in Rust*!
[Rust](http://rust-lang.org) 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](https://twitter.com/ThisWeekInRust) or [send us a pull request](https://github.com/rust-lang/this-week-in-rust).
Want to get involved? [We love contributions](https://github.com/rust-lang/rust/blob/master/CONTRIBUTING.md).

*This Week in Rust* is openly developed [on GitHub](https://github.com/rust-lang/this-week-in-rust).
If you find any errors in this week's issue, [please submit a PR](https://github.com/rust-lang/this-week-in-rust/pulls).

# Updates from Rust Community

No papers/research projects this week.

### Official
* [Brainstorming Async Rust's Shiny Future](https://blog.rust-lang.org/2021/04/14/async-vision-doc-shiny-future.html)
* [Foundation] [Introducing Florian Gilcher](https://foundation.rust-lang.org/posts/2021-04-08-introducing-florian-gilcher/)
* [Foundation] [Introducing Peixin Hou](https://foundation.rust-lang.org/posts/2021-04-08-introducing-peixin-hou/)

### Newsletters
* [This Month in Rust GameDev #20 - March 2021](https://gamedev.rs/news/020/)

### Project/Tooling Updates
* [Progress report on rustc_codegen_cranelift (April 2021)](https://bjorn3.github.io/2021/04/13/progress-report-april-2021.html)
* [IntelliJ Rust: Updates for 2021.1](https://blog.jetbrains.com/rust/2021/04/08/intellij-rust-updates-for-2021-1/)
* [IntelliJ Rust Changelog #145](https://intellij-rust.github.io/2021/04/12/changelog-145.html)
* [rust-analyzer Changelog #72](https://rust-analyzer.github.io/thisweek/2021/04/12/changelog-72.html)
* [Ballista has been donated to the Apache Arrow project](https://www.reddit.com/r/rust/comments/mo63t3/ballista_has_been_donated_to_the_apache_arrow/)

### Observations/Thoughts
* [Rust in Production: MeiliSearch](https://serokell.io/blog/rust-in-production-meilisearch)
* [Rust is for Professionals](https://gregoryszorc.com/blog/2021/04/13/rust-is-for-professionals/)
* [Rust async is colored, and that's not a big deal](https://morestina.net/blog/1686/rust-async-is-colored)
* [Using Rust for Scientific Numerical applications: Learning from Past Experiences](https://blog.esciencecenter.nl/using-rust-for-scientific-numerical-applications-learning-from-past-experiences-798665d9f9f0)
* [PlaintDB Servers - another milestone reached](https://dev.to/ecton/plaintdb-serves-another-milestone-reached-kl3)
* [Why Rust for Robots?](https://dev.to/tangramvision/why-rust-for-robots-4nmd)
* [Integrating const-generics to nalgebra 0.26](https://www.dimforge.com/blog/2021/04/12/integrating-const-generics-to-nalgebra/)
* [podcast] [Building with Rust: Tim McNamara on Rust in Action](https://anchor.fm/building-with-rust/episodes/Building-with-Rust-Tim-McNamara-on-Rust-in-Action-eugoal/a-a1ptlh) [[transcript]](https://github.com/seanchen1991/building-with-rust/blob/main/transcripts/002.md)

### Rust Walkthroughs
* [Build an End-to-End Encrypted messaging app in rust, with the Ockam crate, in this step by step guide.](https://github.com/ockam-network/ockam/tree/develop/documentation/guides/rust/get-started#readme)
* [Introducing easy-cast](https://kas-gui.github.io/blog/easy-cast.html)
* [Why Rust strings seem hard](https://www.brandons.me/blog/why-rust-strings-seem-hard)
* [Rust shenanigans: return type polymorphism](https://loige.co/rust-shenanigans-return-type-polymorphism/)
* [Writing Neovim plugins in Rust](https://blog.usejournal.com/a-detailed-guide-to-writing-your-first-neovim-plugin-in-rust-a81604c606b1)
* [A zero-overhead linked list in Rust](https://aloso.github.io/2021/04/12/linked-list.html)
* [Integrating Rust into Python](https://www.vortexa.com/insight/integrating-rust-into-python)
* [Setting Up a gRPC Protobuf Server With Tonic](https://dev.to/transienterror/setting-up-a-grpc-protobuf-server-with-tonic-218e)
* [Getting started with Kafka and Rust: Part 2](https://dev.to/abhirockzz/getting-started-with-kafka-and-rust-part-2-354f)
* [Rust lib error management, multiple enum approach](http://www.tglman.com/posts/rust_lib_error_management.html)
* [Asynchronous streams in Rust (part 2) - Cancelling expired requests](https://gendignoux.com/blog/2021/04/08/rust-async-streams-futures-part2.html)
* [series] [Engaging Warp: REST API with Rust](https://dev.to/rogertorres/series/12179)
* [ZH] [series] [Build GraphQL services based on Async Rust using tide + async-graphql + mongodb (基于 Async Rust 构建 GraphQL 服务，使用 tide + async-graphql + mongodb) - Part 1](https://blog.budshome.com/budshome/gou-jian-rust-yi-bu-graphql-fu-wu-:ji-yu-tide-+-async-graphql-+-mongodb(1)--qi-bu-ji-crate-xuan-ze)
* [video] [Flocking Boids in Rust: With Piston vs Tetra vs Amethyst vs Bevy](https://youtu.be/e0n9v565HR4)

### Miscellaneous
* [Rust, not Firefox, is Mozilla's greatest industry contribution](https://www.techrepublic.com/article/rust-not-firefox-is-mozillas-greatest-industry-contribution/)
* [AWS's Shane Miller to head the newly created Rust Foundation](https://www.zdnet.com/article/awss-shane-miller-to-head-the-newly-created-rust-foundation/)
* [[RFC] Rust support for Linux kernel](https://lkml.org/lkml/2021/4/14/1023)
* [A look at LLVM - comparing clamp implementations](https://secret.club/2021/04/09/std-clamp.html)
* [Tokio-uring design proposal](https://www.reddit.com/r/rust/comments/mmz1sg/tokiouring_design_proposal/)
* [Google is now writing low-level Android code in Rust](https://arstechnica.com/gadgets/2021/04/google-is-now-writing-low-level-android-code-in-rust/)
* [Rust in the Linux kernel](https://security.googleblog.com/2021/04/rust-in-linux-kernel.html)

# Crate of the Week

This week's crate is [dipa](https://docs.rs/dipa), a crate to derive delta-encoding for Rust data structures.

Despite a lack of nominations, llogiq is very pleased with his choice.

[Submit your suggestions and votes for next week][submit_crate]!

[submit_crate]: https://users.rust-lang.org/t/crate-of-the-week/2704

# 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][guidelines].

[guidelines]: https://users.rust-lang.org/t/twir-call-for-participation/4821

# Updates from Rust Core

329 pull requests were [merged in the last week][merged]

[merged]: https://github.com/search?q=is%3Apr+org%3Arust-lang+is%3Amerged+merged%3A2021-04-05..2021-04-12

* [allow specifying alignment for functions](https://github.com/rust-lang/rust/pull/81234)
* [fix handling of `--output-format json` flag](https://github.com/rust-lang/rust/pull/82497)
* [don't tell users to use a nightly flag on the stable channel](https://github.com/rust-lang/rust/pull/84055)
* [improve trait/impl method discrepancy errors](https://github.com/rust-lang/rust/pull/84014)
* [account for `ExprKind::Block` when suggesting .into() and deref](https://github.com/rust-lang/rust/pull/83952)
* [let `#[allow(unstable_name_collisions)]` work for things other than function](https://github.com/rust-lang/rust/pull/81922)
* [add `bad_asm_style` to `HardwiredLints`](https://github.com/rust-lang/rust/pull/84068)
* [improve debuginfo for closures and async functions on Windows MSVC](https://github.com/rust-lang/rust/pull/83941)
* [use `AnonConst` for `asm!` constants](https://github.com/rust-lang/rust/pull/83916)
* [add `FromIterator` and `IntoIterator` impls for `ThinVec`](https://github.com/rust-lang/rust/pull/83821)
* [add `strong_count` mutation methods to `Rc`](https://github.com/rust-lang/rust/pull/83476)
* [use a `SmallVec` in `impl_or_trait_item`](https://github.com/rust-lang/rust/pull/83932)
* [use `FromStr` trait for number option parsing](https://github.com/rust-lang/rust/pull/82483)
* [reduce threads spawned by ui-tests](https://github.com/rust-lang/rust/pull/81942)
* [core: disable `ptr::swap_nonoverlapping_one`'s block optimization on SPIR-V](https://github.com/rust-lang/rust/pull/83019)
* [stabilize `cmp_min_max_by`](https://github.com/rust-lang/rust/pull/81047)
* [stabilize `peekable_peek_mut`](https://github.com/rust-lang/rust/pull/81938)
* [stabilize `duration_saturating_ops`](https://github.com/rust-lang/rust/pull/84090)
* [stabilize `atomic_fetch_update` methods on `AtomicBool` and `AtomicPtr`](https://github.com/rust-lang/rust/pull/84085)
* [fix `HashMap`/`HashSet` LLDB pretty-printer after hashbrown](https://github.com/rust-lang/rust/pull/83920)
* [futures: move `try_fold`, `try_for_each`, and `try_for_each_concurrent` to `StreamExt`](https://github.com/rust-lang/futures-rs/pull/2342)
* [futures: add `stream::Peekable::`{`next_if`, `next_if_eq`}](https://github.com/rust-lang/futures-rs/pull/2379)
* [fix perf regression in `rustdoc::bare_urls`](https://github.com/rust-lang/rust/pull/84034)
* [rustdoc: cleanup handling of associated items for intra-doc links](https://github.com/rust-lang/rust/pull/83849)
* [rustdoc: sort search index items for compression](https://github.com/rust-lang/rust/pull/83835)
* [rustdoc: store intra-doc links in Cache instead of on items directly](https://github.com/rust-lang/rust/pull/83833)
* [rustdoc: use `ThinVec` in a few places](https://github.com/rust-lang/rust/pull/83828)
* [rustdoc: merge idents when generating source content](https://github.com/rust-lang/rust/pull/83992)
* [clippy: fix false positive in `single_component_path_imports` lint](https://github.com/rust-lang/rust-clippy/pull/6905)
* [clippy: fix `explicit_into_iter_loop`](https://github.com/rust-lang/rust-clippy/pull/6982)
* [clippy: consider mutability on `useless_vec` suggestions](https://github.com/rust-lang/rust-clippy/pull/7036)
* [clippy: fix `missing_panics_doc` not detecting `assert_eq!` and `assert_ne!`](https://github.com/rust-lang/rust-clippy/pull/7029)

## Rust Compiler Performance Triage

A very quiet week overall.

Triage done by **@simulacrum**.
Revision range: [d322385..5258a74](https://perf.rust-lang.org/?start=d32238532138485c80db4f2cd596372bce214e00&end=5258a74c887f8ae14717e1f98b652b470877ce4e&absolute=false&stat=instructions%3Au)

1 Regressions, 0 Improvements, 0 Mixed

## Approved RFCs

Changes to Rust follow the Rust [RFC (request for comments) process](https://github.com/rust-lang/rfcs#rust-rfcs). These
are the RFCs that were approved for implementation this week:

* [RFC: -C export-executable-symbols](https://github.com/rust-lang/rfcs/pull/2841)

## Final Comment Period

Every week [the team](https://www.rust-lang.org/team.html) announces the
'final comment period' for RFCs and key PRs which are reaching a
decision. Express your opinions now.

### [RFCs](https://github.com/rust-lang/rfcs/labels/final-comment-period)

* [disposition: merge] [RFC: Reserved prefixes in the 2021 edition](https://github.com/rust-lang/rfcs/pull/3101)
* [disposition: merge] [try_trait_v2: A new design for the ? desugaring](https://github.com/rust-lang/rfcs/pull/3058)
* [disposition: merge] [add const-ub RFC](https://github.com/rust-lang/rfcs/pull/3016)
* [disposition: merge] [Target tier policy](https://github.com/rust-lang/rfcs/pull/2803)
* [disposition: postpone] [RFC: Custom DSTs](https://github.com/rust-lang/rfcs/pull/2594)

### [Tracking Issues & PRs](https://github.com/rust-lang/rust/labels/final-comment-period)

* [disposition: merge] [Cautiously add IntoIterator for arrays by value](https://github.com/rust-lang/rust/pull/84147)
* [disposition: merge] [Stabilize Duration::MAX](https://github.com/rust-lang/rust/pull/84120)
* [disposition: merge] [Stabilize `impl From<[(K, V); N]> for HashMap`](https://github.com/rust-lang/rust/pull/84111)
* [disposition: merge] [Allow setting `target_family` to multiple values, and implement `target_family="wasm"`](https://github.com/rust-lang/rust/pull/84072)
* [disposition: merge] [Stabilize pat2015 but leave :pat2021 gated](https://github.com/rust-lang/rust/pull/83386)
* [disposition: merge] [Update BARE_TRAIT_OBJECT and ELLIPSIS_INCLUSIVE_RANGE_PATTERNS to errors in Rust 2021](https://github.com/rust-lang/rust/pull/83213)
* [disposition: merge] [Tracking Issue for 'ordering helpers'](https://github.com/rust-lang/rust/issues/79885)
* [disposition: merge] [Tracking issue for array::from_ref and array::from_mut](https://github.com/rust-lang/rust/issues/77101)
* [disposition: merge] [Tracking issue for x86 bittest intrinsics](https://github.com/rust-lang/rust/issues/59414)
* [disposition: merge] [Tracking issue for RFC 2457, "Allow non-ASCII identifiers"](https://github.com/rust-lang/rust/issues/55467)

## New RFCs

* [`#[derive(Default)]` on enums with a `#[default]` attribute #3107](https://github.com/rust-lang/rfcs/pull/3107)
* [Add :value macro capture designator](https://github.com/rust-lang/rfcs/pull/3106)

# Upcoming Events

### Online
* [April 20, Washington, DC, US - The Rust Borrow Checker—A Deep Dive - Rust DC](https://www.meetup.com/RustDC/events/ntvrgsyccgblb)
* [April 21, Vancouver, BC, CA - Rust Study/Hack/Hang-out night - Vancouver Rust](https://www.meetup.com/Vancouver-Rust/events/npqfbsyccgbcc/)
* [April 27, Dallas, TX, US - Last Tuesday - Dallas Rust](https://www.meetup.com/Dallas-Rust/events/jqxqwryccgbkc/)

### North America
* [April 14, Atlanta, GA, US - Grab a beer with fellow Rustaceans - Rust Atlanta](https://www.meetup.com/Rust-ATL/events/qxqdgryccgbsb/)

### Asia Pacific
* [April 19, Wellington, NZ - IGNITION: What is Rust and why should I care? Rust at work & at play - Rust Wellington](https://www.meetup.com/Rust-Wellington/events/277270667)

### Europe
* [April 21, Moscow, RU - Monthly Meetup - Rust Moscow](https://www.meetup.com/ru-RU/Rust-%D0%B2-%D0%9C%D0%BE%D1%81%D0%BA%D0%B2%D0%B5/events/277259838/)

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][community] for access.

[calendar]: https://www.google.com/calendar/embed?src=apd9vmbc22egenmtu5l6c5jbfc%40group.calendar.google.com
[community]: mailto:community-team@rust-lang.org

# Rust Jobs

**Slight**

* [Software Engineer - Core Team, Rust (Remote)](https://www.slight.co/jobs/software-engineer-core)

**Kraken**

* [Several Rust Engineering Positions are Available (Remote)](https://jobs.lever.co/kraken?team=Engineering)

*Tweet us at [@ThisWeekInRust](https://twitter.com/ThisWeekInRust) to get your job offers listed here!*

# Quote of the Week

> What I actually value on a daily basis in \[rust is\]
> I can call code written by other people without unpleasant surprises.
>
> ```
> async fn verify_signature(token: &Jwt) -> Result<Claims, VerificationError>
> ```
>
> Looking at a code snippet:
>
> * I know my JWT token won't be mutated, just accessed ( `&` );
> * I know the function will probably perform some kind of I/O ( `async` );
> * I know that the function might fail ( `Result` );
> * I know its failure modes ( `VerificationError` ).

– [Luca Palmieri on Twitter](https://twitter.com/algo_luca/status/1380928103019597827)

Thanks to [Nixon Enraght-Moony](https://users.rust-lang.org/t/twir-quote-of-the-week/328/1031) for the suggestion!

[Please submit quotes and vote for next week!](https://users.rust-lang.org/t/twir-quote-of-the-week/328)

*This Week in Rust is edited by: [nellshamrell](https://github.com/nellshamrell), [llogiq](https://github.com/llogiq), and [cdmistman](https://github.com/cdmistman).*

<small>[Discuss on r/rust](https://www.reddit.com/r/rust/comments/mr4eg0/this_week_in_rust_386/)</small>
