Home Artists Posts Import Register

Downloads

Content

Today we're talking about how to design your projects in Rust without using inheritance.

I'd love your thoughts on this method, melding normalisation with state machines is not something I've seen elsewhere, I hope it's a good idea. (I think it is!)

Thanks so much for your support, I had a great time with this one, once I'd figured out the right state machine demo!

Keep an eye out for an extra announcement next week, things are HAPPENING!

Tris <3

Files

Comments

Anonymous

I think the title might be mixed up a bit. I’ve noticed one weakness with Typescript where I want to make a custom simple type like an integer that’s called “identifier”. Sometimes, I want to make sure that only an identifier generated by a specific library is stored in that field. Typescript would allow any number into that field unless you make it an object, which then incurs significant runtime cost. Rust better supports this with type aliases, but also creating a struct no longer is something that has to be so avoided due to zero cost abstraction.

Anonymous

This might not be the best question. But I'll still go ahead. What would be the best way to model such state machines to model Long running transitions? Say, the mario transitions happen at random times in 5 minute game. One thing that comes to my mind is use some async wrapper on top of the mario model .

noboilerplate

the beauty of rust is that you KNOW with certainty that this code can be very easily modified to work safely in an async environment. If you want a lot of folks to wade in on this question, ask in #programming on my discord! :-)