Daily Note - 2025-04-25
Hey, I'm Hanno! These are my daily notes on Crosscut, the programming language I'm creating. If you have any questions, comments, or feedback, please get in touch!
In imperative languages, side effects are implicit. You call a function, and at the call site, you won't see what it can do. It could be anything! That (very deliberately) is not the case in purely functional languages, which track side effects explicitly. And traditionally, they do that using values.
The classic approach to that is monads (in languages like Haskell). I was considering a different approach based on linear types. But it comes down to the same thing: If a function does something, then that "something" is reflected in the values it accepts and returns.
As a natural result, statements (which are a mainstay in imperative languages) are deemphasized or do not exist at all. Since every operation exchanges values with others, all operations within a function body tend to end up as part of a single expression.
Hey, you! Want to subscribe to my daily notes? Just let me know (maybe include a nice message, if you're up for it), and I'll send you an email every time I post a new one.