Search

Items tagged with: Rustlang



Tl'dr #rustlang is a great collaboration opportunity for @gnome and @kde.

A long long time ago, #freedesktop initiative was created for precisely this goal. While in many ways it was a success story (especially in terms of establishing standards), it came short in one specific aspect: code collaboration.

Most freedesktop (all?) projects were and are almost exclusively developed and maintained by GNOME folks. That's not very surprising, given that C (being that lowest common denominator) had to be the programming language of choice. Just like most GNOME folks wouldn't want to touch C++, KDE folks don't particularly enjoy coding in C either. I know both have their reasons and the point here is not to play the blame game here.

There is not much point in dwelling in the past here but if we decide to write all future infrastructure/non-UI projects (that would have otherwise been written in C or C++) in Rust, there's a great potential for collaboration, I believe.

Talk is cheap, you could say and I agree. Hence why I've taken some steps in this direction already: github.com/dbus2/



Microsoft is rewriting parts of GDI in Rust, as evidenced by a new file called "win32kbase_rs.sys" which contains a complete reimplementation of the REGION type in rust, and a vive ID called "Rust_GDI_REGION".

#rust #rustlang #microsoft #windows



Over the Easter holidays I experimented a bit with building Rust code with meson instead of cargo.

Specifically I tried building a GStreamer plugin with a few dozen Rust dependencies, but the same applies in a similar way to GTK/GNOME applications or literally anything else.

A write-up of the results with a lot of details can be found here: coaxion.net/blog/2023/04/build…

#RustLang #GStreamer #GNOME #GTK #meson #cargo #BuildSystems


🦀 "Why the Rust Community Should Be Worried About the New Carbon Language"

👉 should we?

👉 If we some language can do what Rust can do but more simpler, we should be happy to switch but is that the case here?

Article:
towardsdev.com/why-the-rust-co…

#rustlang #rust #cpp #carbon





:youtube_logo: In today's video, I have some strange recommendations on how to learn #RustLang! :rust:
youtu.be/2hXNd6x9sZs





Watch Philip's talk at #FOSDEM, where he covers the API and prototypes for 'connectbyname', a library function that takes as input a DNS name and returns a TLS connection, as well as a new EDNS(0) option called Proxy Control option that allows stub resolvers to send requirements to a local proxy.

We're developing an #API in #rustlang that can internally use asynchronous #DNS lookups, implement Happy Eyeballs, support #DANE, SVCB/HTTPS, encrypted client hello, etc.

fosdem.org/2023/schedule/event…



As part of the optimizations, there are a lot fewer temporary allocations now, e.g. for NUL-terminated strings.

Also, in addition to better performance, the code generation improvements also reduce the binary size considerably.

Some GStreamer plugins saw reductions of 15-20% 🥳

#GStreamer #Rust #RustLang





@TauriApps is awesome!

I just made a standalone app for emoji-mart using tauri.

It is very easy to use as a developer, starts fast, binaries are small (2mb for this project) and packaging just works out of the box.

For this project I did not even had to write a single line of rust, so you don't need to be comfortable with #rustlang to be able use it.

github.com/Simon-Laux/tauri-em…

#tauri



let floor = Floor::default();<br>let mut bowl = Bowl::new();<br>let mut cat = Cat::mew();<br><br>bowl.place_on(&floor);<br>cat.sit_on(&bowl);<br><br>let floor: &mut Floor = unsafe {<br>    &mut *(&floor as *const Floor as *mut Floor)<br>};<br><br>floor.lower_by(50 * CM);<br>

Levitation needs some unsafe code, but not around the cat, cats don't take fall damage.

Original post by @Kyu : meow.social/@Kyu/1095710305682…

#RustCataStructures #rust #RustLang #cat #CatsOfMastodon


Not all cats have the gift of levitation.
Those that do, however, do like to flaunt it.


The Rust base64 crate got a new release the other day, which removed (or rather deprecated for now) the simple encoding/decoding API and requires quite a bit boilerplate for such a simple task.

The maintainer does not see the point in providing a simpler API for the common cases because if the API is too difficult to use then Rust is just the wrong language for you 🙄

Too bad the crate has such a prominent name on crates.io and is used so widely. I hope that doesn't turn away too many beginners because something as simple as base64 handling is so complicated.

The data-encoding crate looks like a good alternative for the same tasks. It provides the same amount of flexibility while still providing a simple API for the common tasks.

lib.rs/crates/data-encoding

#rust #RustLang


Now that we made it all through the holidays, we're happy to do some releases again!

First up is our #RPKI relying party software Routinator. 🚀 Version 0.12.1 fixes a small number of bugs. Most importantly, the #TLS-enabled servers for both HTTP and RTR now also accept private keys formatted as PKCS#1 RSA keys rather than only accepting PKCS#8 keys. #RoutingSecurity #rustlang

github.com/NLnetLabs/routinato…





The experimental Rust PR to add a more expressive "interop" ABI on top of the C ABI is IMHO the most exciting new effort that happened in Rust in the last few years.

Thanks to @josh and others for starting this very important work 🥳​

github.com/rust-lang/rust/pull…

Also @Mara's reply seems to indicate that some serious thought is now also put into other related areas, especially for handling Rust dynamic libraries.

github.com/rust-lang/rust/pull…

Very exciting stuff for making Rust a better choice in various areas where exactly these topics were slowing down or hindering adoption.

#Rust #RustLang


First video in the "decrusted" series where we peel back the crust of the serde crate is now up: youtu.be/BI_bHCGRgMY. I quite like the format, so expect to see more of these! #rustlang


🦀📕 Rust Atomics and Locks is now available as ebook! 🎉

Pre-ordered printed copies should start shipping in a few weeks. ⌛️

#rustlang

marabos.nl/atomics/




🦀​ Rust 🦀​ people, is there a way to use conditional compilation in the match parts of a declarative macro? Other than duplicating the whole macro definition.

Basically something like

macro_rules! foo(<br>    ($x:expr) => { {<br>        println!("{}", $x);<br>    }};<br>    #[cfg(target_os = "linux")]<br>    ($x:expr, $y:expr) => { {<br>        println!("{} {}", $x, $y);<br>    }};<br>);<br>

This currently fails compiling: play.rust-lang.org/?version=st…

#Rust #RustLang


My first commit (written with antoyo) was merged in GCC! \o/

It allows us to continue improving the GCC backend for the Rust compiler (github.com/rust-lang/rustc_cod…) without needing a custom libgccjit version. :)

github.com/gcc-mirror/gcc/comm…

#rustlang #gcc