Rust - You Complete Me (And then drop me, because I'm out of scope)
To My Dearest Rust,
Ever since I laid eyes on your braces and semicolons, I knew, there was something special about you. This past winter holiday that we spent together has changed my life. I’ll never be the same. The way you embrace life by being explicit about the death of objects, the way you force me to be clear when I’m borrowing your things. Sure, it was a bumpy beginning. I thought maybe I might run back to safe, warm, python’s arms. But you didn’t give up on me, you kept warning me that I was making everything mutable when I didn’t have to. And now, whatever happens, I’m a better man for having known you.
Some might say being explicit about the length of our lifetimes is macabre, but I find it invigorating. It’s a reminder that some things will outlive others, and being able to see that, and know the day some of our objects will die is a reminder that most of our data is related, and sometimes we need to spell out how up front to prevent garbage building up, which would force us to pause and deal with it later.
And you saved me from modifying my variables in loops. I never even knew how many times I made that mistake and had to double back to fix those errors. I always thought I was being cool, reusing variables, but you called me out and made sure I never did that after I gave them to someone else. This made me frugal with my CPU and memory by helping me think about when and where exactly I’d spend them. Explicit mutability? How about explicit cuteability.
And just the other day, when I asked you if we could go multi-threaded together, you didn’t just go along easily. You didn’t just hand me the keys and make me drive the whole process. You challenged me to use mutexes and reference counted pointers. You held my hand while I fumbled through it, and offered encouraging tips, with a lot of reminders to wrap things in safer containers before we went out into the cold, brutal multi-threaded world. Because of you, I’ll never have to feel the cold sting of corrupted memory again.
My love, Rust, I don’t know if we can be together. You’re so new to this world and I’m not sure everyone will understand you. But I know I’ll do whatever I can to tell the world about your beauty and grace.
Love Always, - Clint
p.s. lets meet up again around spring break.