i'm coding my first vulkan based examples to learn what about scopes needs improving and i notice that i have practically no sugar around mutable values, or rather: values-with-addresses aka references.

right now, to get a value that can be referenced, one has to define one via alloca/alloca-memory, and then use store to write to that value, and load to retrieve it

writing an overloadable = that performs a store is easy, but making loads invisible is not so simple

the first idea is to make a new builtin reference type that can be used to produce hidden pointers, and then to reduce references to immutable values for all basic operation arguments on the fly; the IR generator must then generate load instructions when it encounters a reference value. in the language, one would then declare these via var <value-name> [@ <array-size>] [= <value>], which internally translates to the equivalent of `let = (alloca[-array] []); store ; let <val

View sjlj_exc.cpp
struct ExceptionPad {
jmp_buf retaddr;
Exception exc;
void invoke(const Exception &exc) {
this->exc = exc;
longjmp(retaddr, 1);
View gist:3a405bd27c88927f0dcfb01115419b8a
Miscellaneous Ungrouped Timers
---User Time--- --System Time-- --User+System-- ---Wall Time--- --- Name ---
2.7520 ( 65.6%) 0.9080 ( 97.8%) 3.6600 ( 71.5%) 3.6596 ( 71.7%) Code Generation Time
1.4400 ( 34.4%) 0.0200 ( 2.2%) 1.4600 ( 28.5%) 1.4419 ( 28.3%) LLVM IR Generation Time
4.1920 (100.0%) 0.9280 (100.0%) 5.1200 (100.0%) 5.1015 (100.0%) Total
View gist:6e89af822173a4e17251d722e7e35d3c
A new intuition about a more life-like cellular automata / reaction-diffusion design:
I feel that designing systems that imitate at least three invariants of the universe closely
might yield new and interesting patterns:
A. The universe is continuously expanding.
B. The sum energy of the universe always remains the same.
C. Entropy in the universe is ever-increasing. (Second law of thermodynamics)
View gist:d856a9410095472e087d03729d871f14
pow7(x) ⮕ ret: pow(x, 7) ⮕ ret;
pow(x, n) ⮕ ret: eq(n, 0) ⮕ _2;
_2(x): branch(x, then3, elseif4);
then3: pow.ret(1);
elseif4: mod(pow.n, 2) ⮕ _5;
_5(x): eq(x, 0) ⮕ _6;
_6(x): branch(x, then7, else10);
then7: div(pow.n, 2) ⮕ _8;
View interpreter.lua
Label = {}
Closure = {}
Parameter = {}
none = setmetatable({}, {
__tostring = function () return "none" end
View cotmta.cpp
// Syntax demo for writing Cheney on the MTA style code in C++11
// (see for more info)
// Using variadic macros, I managed to design a syntax that is good enough
// to write in, as opposed to the automated code generation that COTMTA
// originally envisioned.
// key reasons why I intend to use this:
// * Writing a Scheme interpreter that keeps the C stack compact

Fractional Arithmetic

When we represent numbers as fractions of integer numerator and denominator, we can perform arithmetic on these fractions. This is useful for situations where we wish to work with fractional values, but need lossless results, something that floating point encoding can not always guarantee.

We represent a fractional number as a tuple of two integer values, separated by a slash:


A Decentralized Virtual Reality Protocol

by Leonard Ritter, Duangle GbR

*The metaverse can be a utopia or it can be a dystopia. And we are very fortunate that the PC platform is the number one platform for serious computing today, and the internet underlying it are all completely open technologies. Anybody can build software. Anybody can distribute it. Anybody can do anything without getting anybody's permission. I feel we have seen a major retraction from that great state of affairs over the past decade, as closed platforms (...) have grown to the forefront of the industry. (...) And I wanted to point out that this was not inevitable. (...) As we are creating a new medium together it would be really tragic if the future metaverse that binds all humanity together into shared online environments were a closed platform controlled by a giant corporation. As always, they would use it to spam you with advertising. They would use it to gather information about your private life

View error_handling.txt
A program error occurs.
What immediate context might we want to provide?
1. File, line & column (let's call it an anchor) of the expression causing the error.
2. Anchor of each of the expressions that processed & forwarded values to the expression which caused the error.
* This gives you a quasi traceback of the execution chain. When the language is not
stack based, it's a challenge to figure out which preceding continuations to select
for printing.
3. For all participating expressions, the values of their input arguments when the error was caused.