There have been a number of debates over the years about the merits of checked versus unchecked exceptions. Kotlin’s approach when doing interop with Java is to ignore checked exceptions altogether, effectively turning every exception into unchecked exceptions. You may have your opinions about whether you prefer checked or unchecked exceptions, but I’m here to tell you both are problematic. If you look deeply enough into this, you may come to the conclusion I think all exceptions are problematic.
Whether you wanted to find out about object oriented Rust yourself, or you wanted to see why in the world I’m talking about object oriented rust, you are here. And so let us talk about object oriented Rust. Object oriented Rust is not so outlandish. Many folks think of Rust as a functional language, and while there are plenty of functional paradigms in Rust, many of those paradigms are also available to other languages in one way or another.
In my last post I talked about how I made a enjoyable little display of fireworks for the terminal. It was fun to make and it’s fun to watch when meetings get boring (always). Fireworks can be found here. However after running my fireworks for a while, I started noticing some funky details. The fireworks could be a little flickery at times. And not in a good way. Well we couldn’t have that!
Recently I embarked on a fun little side project. There have been just too many rampant fireworks going on outside and I was feeling a little left out, so I decided to make some of my own. Given I have no experience with anything like OpenGL at all, and was feeling like learning termion since I consistently use tui with a termion backend and only sort of understand how it works, I decided terminal fireworks would be the way to go.
I had a whole lot of fun with the Typeracer post I made showing how the program itself had changed throughout its lifetime. What I didn’t mention (although is fairly obvious if you look at the code) is that Typeracer was my first real exposure to Rust. I went through a bit of the rust book and wrote a tiny compression tool that did a sort of run length encoding algorithm, but both of them were super simple and I really wanted something I could work on for longer to understand the language.