Crosscut

Daily Thought - 2024-04-23

Hey, I'm Hanno! These are my daily thoughts on Crosscut, the programming language I'm creating. If you have any questions, comments, or feedback, please get in touch!

This thought was published before Crosscut was called Crosscut! If it refers to "Caterpillar", that is the old name, just so you know.

< back to list

I've been talking about how to step through Caterpillar programs, forward and backward, undoing and redoing changes to their state. But so far, I've completely glossed over the topic of I/O. How would that interact with such a capability?

Graphics are typically re-rendered every frame, based on the current frame. So it wouldn't matter in that case. File I/O could work, if instructions/events carry enough information to rewind changes there too. With a log file, you could acknowledge the rewind by logging a message about it, then just continue from there.

What's not at all clear to me, is how to hook I/O into this whole system in the first place. It seems pretty straight-forward on the instruction level. But what about Event Sourcing? That's designed to explicitly not do any I/O when applying events. More to think about, for sure.

<< previous thoughtnext thought >>

Hey, you! Want to subscribe to my daily thoughts? Just let me know (maybe include a nice message, if you're up for it), and I'll send you an email whenever I post a new one.