slash dev slash null

stuff about puters

Category: Rust

Rust Extension Methods

Seven years ago I was working on a system that had a fat client desktop app written in C# and a Java backend. I signed up for a week-long C# training programme. I was fascinated about the bits of C# that had evolved away from Microsoft J++. A lot of the differences that still stuck in my mind were all about boilerplate removal. One of those was C# Extension Methods. I have posted some sample code of Rust Extention Methods over on GitHub.    Read the rest of this entry »

Rust Pickling 

The first thing item to research on my Rust spike is picking. A quick survey of the landscape indicates that serde appears to be the current defacto standard framework. Pickling was an area that I chose to hand code in the TRex Scala implementation. Why? Because Scala’s pickling engine crashed my JVM and wasn’t yet the stage of a stable disk format. I want to have no external dependencies for the inner Paxos library and as few as possible elsewhere. As Scala’s official pickling engine wasn’t ready for prime time, I was on my own. I had some fun writing my own ByteChain based pickling where I wrote a compact binary wire encoding for unsigned integers. With Rust does serde put me in a better place? Read the rest of this entry »

Why Rust for TRex?

My programming career started out with C and C++ last century. I then switched to Java for a long while then finally moved onwards and upwards into Scala. Along the way I have put JavaScript into production and written a JavaScript authentication library others use. There was also a bit of PHP on the side which I don’t draw attention to. Why not return to C++ for a systems programming language port of Trex? Or try D? Why Rust?  Read the rest of this entry »

Rust FTW?

It has been on the back of my mind for a while that Scala might not be too many folks first choice language to implement a Paxos library. So I have been considering the options for porting TRex onto a systems programming language.

A couple of weeks ago I started reading The Rust Programming Language. Before I knew it I have been sucked in and find myself mildly, and occasionally widely, enthusiastic about Rust. There are still a lot of little steps I need to test out, and lessons I need to learn before I make the decision to do a full port. I thought to blog about those steps and lessons as I go long. For my next post, I will explain why I started out looking at Rust rather than another language.