The !-modality is a comonad. In particular, it is a functor; we can lift any function/procedure to work on perennial types with
map, \( A \multimap B \vdash !A \multimap !B \).
Concatenative languages lend themselves to rewriting because they do not bind variables and thus do not incur any confusion with renaming/scope (compositional rather than applicative).
Monads for effects are familiar to the Haskell programmer; they were introduced by Wadler's "Monads for functional programming" and are the accepted way to work with side effects in a lazy language.
As I wrote elsewhere, garbage collection - manual memory management correspond to intuitionistic logic - linear logic. So garbage collection is a technology with logical implications.
Suppose we wish to compute successive differences. In J:next