[rougenoir] A Clone of the Linux Kernel's Red-Black Tree in Rust

63 points RollElegant5275 8 comments

Hello everyone,

This project has been sitting idle on my disk for a couple of months now, unreleased, but used in a private project.

I just released it:

  1. Github: https://github.com/stackmystack/rougenoir

  2. crates.io: https://crates.io/crates/rougenoir

It's a clone of the linux kernel's red-black tree.

The main motivation for it was a need for a balanced tree with callbacks on rebalancing (e.g. used for interval trees).

I decided to clone the linux kernel's version because ... well no real reason but to exercise some unsafe rust.

It's tested with miri, so can I assume it's 100% safe? Maybe ... The whole point was to learn, and tbh I learned quite a lot.

Contributions and reviews are welcome :)

Cheers.