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 General Dev topics Top

siddhant3030
I’m thinking of buying a monitor that I can rotate to use as a vertical monitor? Also, I want to know if someone is using it for program...
New
New
AstonJ
We have a thread about the keyboards we have, but what about nice keyboards we come across that we want? If you have seen any that look n...
New
foxtrottwist
Here’s our thread for the Keyboardio Atreus. It is a mechanical keyboard based on and a slight update of the original Atreus (Keyboardio ...
New
AstonJ
Inspired by this post from @Carter, which languages, frameworks or other tech or tools do you think is killing it right now? :upside_down...
New
PragmaticBookshelf
Craft your dream role at work by guiding your manager to take your priorities into account when making decisions. Ken Kousen @kenko...
New
Exadra37
I am thinking in buying one as the second monitor for my Thinkpad while I am travelling: Anyone has experience in using on...
New
AstonJ
This might be my next keyboard (the down arrow on my Apple Magic Keyboard has stopped working :icon_rolleyes:) https://cdn.shopify.com/s...
New
First poster: bot
Raspberry Pi security alarm — the basics. In November last year — I started building a DIY security alarm system, using a Raspberry Pi a...
New
CommunityNews
9 fintech engineering mistakes. Read this list unless you want to build a money dissappearing system
New

Other popular topics Top

Exadra37
I am thinking in building or buy a desktop computer for programing, both professionally and on my free time, and my choice of OS is Linux...
New
Rainer
My first contact with Erlang was about 2 years ago when I used RabbitMQ, which is written in Erlang, for my job. This made me curious and...
New
PragmaticBookshelf
Rust is an exciting new programming language combining the power of C with memory safety, fearless concurrency, and productivity boosters...
New
Exadra37
On modern versions of macOS, you simply can’t power on your computer, launch a text editor or eBook reader, and write or read, without a ...
New
AstonJ
I ended up cancelling my Moonlander order as I think it’s just going to be a bit too bulky for me. I think the Planck and the Preonic (o...
New
PragmaticBookshelf
“Finding the Boundaries” Hero’s Journey with Noel Rappin @noelrappin Even when you’re ultimately right about what the future ho...
New
Exadra37
Oh just spent so much time on this to discover now that RancherOS is in end of life but Rancher is refusing to mark the Github repo as su...
New
AstonJ
If you get Can't find emacs in your PATH when trying to install Doom Emacs on your Mac you… just… need to install Emacs first! :lol: bre...
New
New
husaindevelop
Inside our android webview app, we are trying to paste the copied content from another app eg (notes) using navigator.clipboard.readtext ...
New

Latest in General Dev