nilang 0.4.1

A scripting language interpreter for Advent of Code
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
// Patch with closure capturing state
multiplier = 10;

patch($int, $scale, fn(self) {
  return self * multiplier;
});

value = 1;
print(value.scale());

value = 2;
print(value.scale());