[Main website]


It is from the same author ofparadigm/familia-oop. The author analized a lot of FP and OOP paradigm and type system tricks. So it is seem a rather well-tought tecnique.

[1] W. Zhang, Y. Sun, and B. C. D. S. Oliveira, “Compositional Programming,” ACM Trans. Program. Lang. Syst., vol. 43, no. 3, pp. 1–61, Sep. 2021, doi: 10.1145/3460228.

Interfaces have a parameter that is the type to create, called sort. Interfaces can have constructors, and the constructor create the sort passed as interface parameter. Traits are used for defining instances of interfaces, and they accept an interface as parameter.

This tecnique solves theproblem/the-expression-problem.

TODO there are example of code and problems with advanced patterns, try to express in Dok