Fractal Fir

@fractalfir.bsky.social

A young Open-Source developers, with a passion for compilers, procedural generation, and Rust. Currently working on compiling Rust to C(and .NET): https://github.com/FractalFir/rustc_codegen_clr

A cursed C fact of the day: there exists a C compiler out there, for which this assertion will pass: ``` assert(sizeof(float) == sizeof(double)); ``` The Small Device C treats `double` as float: "warning 93: type 'double' not supported assuming 'float'"

I implemented the `int_format_into` feature into the Rust `core` library. It allows you to reuse a buffer when converting an integer into a string: ``` let mut buf = NumBuffer::new(); let string_repr = 12u32.format_into(&mut buf); let other_string_repr = 128u32.format_into(&mut buf); ``` 1/2

Ah, computers never cease to amaze me. For some reason, my "g" key is not working... but it does if I *also* press shift. Meaning I can only type upper-case "G". Thankfully, if i press both caps-lock and shift, they cancel each other out. So, I can still type "g" using 3 keys. I guess it works..

In the spirit of April Fools, i decided to do something silly. I modified my Rust to C compiler to output Holy C. This allowed me to run a small iterator benchmark on Temple OS - meaning Rust is now one of the 2 languages running on that obscure system. Is this useful? No. Is it real? Yes.

A screen-shot from Temple OS, showcasing a small Rust program running. It prints "Calling fold `n` times", and n is increased tenfold on each line.

I have been experimenting with realistic renders of 4D space, using ray marching(image attached below, read alt text for an explanation). Usually, visualisations of 4D space use projections or cross-sections of 4D objects. My render shows how 4D light would appear to your 3D eyes. #art #math

An image of two 4D hyperspheres in a 3D room, with an opening in the 4th dimension. 

The right hypersphere is offset in the 4th dimension, allowing the light to bounce into the 4th dimension. In the reflection, you can see a different part of the 4th dimension, with the opening in a wall, and blue tiles on the floor.

This image was rendered using ray marching, and real-world laws of phsysics, extrapolated to the 4th dimension. The image aims to be photoreal, and accurately describe what one would see if they looked at a 4d world.

I got code written in #rustlang running on a Game Boy :D. While it is not the most useful thing, it is a nice way of showing how compiling Rust to C can allow us to target some old hardware. rustc_codegen_clr(a Rust to C compiler) is still a bit from being fully usable, but it is getting there!

Rust code running on a GameBoy. The screen contains the message "Preparing to run fold *n* times", with the number of iterations starting at 1, increasing tenfold each time, and ending at 10000.