r/ProgrammingLanguages • • Jul 23 '26

Will we see another fundamental programming language feature as revolutionary as the borrow checker?

That is I am mainly curious about compile time features that you design a whole language around rather than optimisations/features that could be applied to most languages. I am mainly inquiring about things that could offer additional robust safety/performance guarantees at compile time rather than runtime. Ideally not things that just offer similar effects to the borrow checker with less restrictive tradeoffs

61 Upvotes

127 comments sorted by

View all comments

Show parent comment

7

u/Jwosty Jul 23 '26 edited Jul 24 '26

You can think of it as a kind of DI, but in its fullest forms you can also manipulate control flow. You couldn't really build async/await or exception handling as a simple injected function (or set of functions), but you can (in principle) with algebraic effects. I think. Please someone correct me if I'm wrong

4

u/gplgang Jul 24 '26

This is correct. It happens to model DI well as you install effect handlers into the environment. The more interesting piece is the non local control flow as a common abstraction instead of iterators vs async vs exceptions and more.