Next chapter in that high-performance #Scala game server. A while back, there was an article about rebasing the core logic processor (purely functional, no IO, no concurrency, bottlenecked on CPU and heap allocations) from #ZIO to ZPure for performance reasons. Now taking it a step further with replacing ZPure with PureLogic (written for this purpose). Uses #Scala3 context functions and "direct style" instead of monads, greatly reducing the number of allocations.

https://blog.pierre-ricadat.com/introducing-purelogic/

Introducing PureLogic: direct-style, pure domain logic for Scala

PureLogic is a new Scala 3 library for writing pure domain logic using direct style instead of monads. It provides 4 capabilities (Reader, Writer, State, Abort) that compose naturally through context functions, with zero dependencies and 7-40x better performance than monadic alternatives.