871 private links
Deliminted continuation is a control flow mechanism involving two primitives prompt
and control
. It resembles call/cc
at a glance, but the scope is different.
For example, the following expression returns 7:
(prompt
(+ 1 (control k
(let ([x (k 1)] [y (k 2)] [z (* x y)])
(k z)))
k
is a continuation reified as a function. To understand the code above, read k
as a blackbox function. Its input replaces the (control ...)
where the part of body of (prompt ...)
starting from the (control ...)
gets evaluated, then the output of (prompt ...)
gets returned as the output of (k ...)
. I find visualizing (prompt ...)
as a box and (control k ...)
as a hole helpful for understanding.
Fascinating paradigm for execution: log all side effects and restore execution deterministically.
Nice to learn about this interesting language. Besides its mixed logical-imperative paradigm and planner, it also has a neuron network module for creating simple nn. Looks like a nice alternative to prolog.
A collection of miniature programming languages which demonstrates various concepts and techniques used in programming language design and implementation.
A nice intro to BCKW and SKI combinator. The most interesting part I found is how dropping some of the combinator gives a different computing world like linear logic. I never thought of that before. Maybe some combinator system reveals a more fundamental picture of computing.
A nice textbook on programming language and type theory. I use it as a supplement material of Types and Programming Languages.
Unison is a langauge where segments of code are not addressed by names (like function names), but by the hash of their contents represented as AST.
By building a language based on this central idea, the problem of dependency conflict is a non-problem. The author also demonstrated the potential of elastic distributed computing based on the idea.
This project reminds me of From Laptop to Lambda: Outsourcing Everyday Jobs to Thousands of Transient Functional Containers, which is built around a similar idea, but implemented as a computing system instead of a programming language.
Very interesting insight for the role of parentheses in lisp languages.
If you model a Lisp as a stack language that evaluates from right to left, each parenthesized block must push exactly one value onto the stack, and must not consume any values.