CommunityNews

CommunityNews

Is Rust Used Safely by Software Developers?

Is Rust Used Safely by Software Developers?.
Rust, an emerging programming language with explosive growth, provides a
robust type system that enables programmers to write memory-safe and data-race
free code. To allow access to a machine’s hardware and to support low-level
performance optimizations, a second language, Unsafe Rust, is embedded in Rust.
It contains support for operations that are difficult to statically check, such
as C-style pointers for access to arbitrary memory locations and mutable global
variables. When a program uses these features, the compiler is unable to
statically guarantee the safety properties Rust promotes. In this work, we
perform a large-scale empirical study to explore how software developers are
using Unsafe Rust in real-world Rust libraries and applications. Our results
indicate that software engineers use the keyword unsafe in less than 30% of
Rust libraries, but more than half cannot be entirely statically checked by the
Rust compiler because of Unsafe Rust hidden somewhere in a library’s call
chain. We conclude that although the use of the keyword unsafe is limited, the
propagation of unsafeness offers a challenge to the claim of Rust as a
memory-safe language. Furthermore, we recommend changes to the Rust compiler
and to the central Rust repository’s interface to help Rust software developers
be aware of when their Rust code is unsafe.

Read in full here:

This thread was posted by one of our members via one of our news source trackers.

Most Liked

timClicks

timClicks

Author of Rust in Action

Thank you! Devtalk is a really wonderful space. It’s great to be part of an enthusiastic community.

DevotionGeo

DevotionGeo

There is a book from newline.co called Fullstack Rust, which teaches actix as well as WebAssembly in rust.

One more thing: I’ve seen the creator Nikolay Kim and other core contributors of actix, fighting over the usage of unsafe. Nikolay was striving for the fastest thing possible, and others were striving for the safest one.
Nikolay Kim left the project and started another library/framework called ntex. Rest of the team replaced almost all the unsafe code with safe code. And the good thing is that actix is still as fast as ntex.

AstonJ

AstonJ

Don’t forget book-hands-on-rust @dwaynebradley :smiley:

Rust in Action’s author @timClicks joined up recently too :smiley:

Ah nice! I didn’t know he started another project and that actix was ‘fixed’ :+1:

Popular Backend topics Top

New
CommunityNews
A new study looks into the dematerialized office, where sensorial experiences such as touch, taste, smell, and sensations of hot or cold ...
New
First poster: bot
Zig Roadmap 2021. From Zig SHOWTIME #21Subscribe to the Zig SHOWTIME Newsletter!https://zig.show0:00 Intro then Language Spec w/ Martin ...
New
First poster: OvermindDL1
What we can learn from “_why” the long lost open source developer… Code might not last forever, but _why proves you can have an impact t...
New
First poster: bot
Ruby: How to Run a Rack app in a Background Thread. Stubbing and mocking are fine, but sometimes you want to test full integration. This...
New
First poster: bot
GitHub - vydd/sketch: A Common Lisp framework for the creation of electronic art, visual design, game prototyping, game making, computer ...
New
New
First poster: bot
Rails adds support for Fiber-safe ActiveRecord ConnectionPools. Ruby on Rails and ReactJS consulting company. We also build mobile appli...
New
CommunityNews
The History of Franz and Lisp. In 1984, while a graduate student in mathematics and in the relatively new Computer Science Department at...
New
First poster: herbert
Why Rust should not have provided unwrap. I see the unwrap function called a lot, especially in example code, quick-and-dirty prototype ...
New

Other popular topics Top

PragmaticBookshelf
A PragProg Hero’s Journey with Brian P. Hogan @bphogan Have you ever worried that your only legacy will be in the form of legacy...
New
AstonJ
SpaceVim seems to be gaining in features and popularity and I just wondered how it compares with SpaceMacs in 2020 - anyone have any thou...
New
AstonJ
I’ve been hearing quite a lot of comments relating to the sound of a keyboard, with one of the most desirable of these called ‘thock’, he...
New
AstonJ
This looks like a stunning keycap set :orange_heart: A LEGENDARY KEYBOARD LIVES ON When you bought an Apple Macintosh computer in the e...
New
PragmaticBookshelf
“Finding the Boundaries” Hero’s Journey with Noel Rappin @noelrappin Even when you’re ultimately right about what the future ho...
New
DevotionGeo
The V Programming Language Simple language for building maintainable programs V is already mentioned couple of times in the forum, but I...
New
AstonJ
Continuing the discussion from Thinking about learning Crystal, let’s discuss - I was wondering which languages don’t GC - maybe we can c...
New
Maartz
Hi folks, I don’t know if I saw this here but, here’s a new programming language, called Roc Reminds me a bit of Elm and thus Haskell. ...
New
PragmaticBookshelf
Author Spotlight: Karl Stolley @karlstolley Logic! Rhetoric! Prag! Wow, what a combination. In this spotlight, we sit down with Karl ...
New
AstonJ
This is cool! DEEPSEEK-V3 ON M4 MAC: BLAZING FAST INFERENCE ON APPLE SILICON We just witnessed something incredible: the largest open-s...
New