diff options
author | Leo Tenenbaum <pommicket@gmail.com> | 2019-10-26 17:02:00 -0400 |
---|---|---|
committer | Leo Tenenbaum <pommicket@gmail.com> | 2019-10-26 17:02:00 -0400 |
commit | 3f13dafdcb617286aae542ab6a2e1ab91d228836 (patch) | |
tree | ea6e59a6609d6aa186b3c32f86ddb1a1a596fdc4 /test.toc | |
parent | e7432359e33880e7d705d1e86397fe676e601505 (diff) |
fixed leaks
Diffstat (limited to 'test.toc')
-rw-r--r-- | test.toc | 36 |
1 files changed, 12 insertions, 24 deletions
@@ -13,39 +13,27 @@ putf @= fn(x: float) { "); }; +asdf @= fn() (int, int) { +2,3}; -N @= 50; -pascal @= fn() [N][]int { - x: [N][]int; - i := 0; - while i < N { - x[i] = new(int, i+1); - i = i + 1; - } - i = 0; - while i < N { - x[i][0] = 1; - x[i][i] = 1; - j := 1; - while j < i { - x[i][j] = x[i-1][j-1] + x[i-1][j]; - j = j + 1; - } - i = i + 1; - } - x +fdsa @= fn() int { + x, y := asdf(); + x + y }; foo @= fn() [3]int { x : [3]int; - x[0] = 0; - x[1] = 1; - x[2] = 2; + x[0] = 1; + x[1] = 2; + x[2] = 3; x }; main @= fn() { // ptriangle @= pascal(); // puti(ptriangle[49][25]); - x @= foo(); + x : [fdsa()]int; + + A, B @= 3, 5; + ASDF @= foo(); }; |