diff options
Diffstat (limited to 'test/aryprm8.awk')
-rw-r--r-- | test/aryprm8.awk | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/test/aryprm8.awk b/test/aryprm8.awk new file mode 100644 index 0000000..b294abb --- /dev/null +++ b/test/aryprm8.awk @@ -0,0 +1,22 @@ +BEGIN { + f(0, a) # nothing + f(1, a) +} +function f(i, a) { + if (i == 0) return + g(a, a) + pr(a) +} +function g(x, y) { + h(y, x, y) +} +function h(b, c, d) { + b[1] = 1 + c[1] = 2 # rewrite + print b[1], d[1] + c[2] = 1 + b[2] = 2 # should rewrite +} +function pr(x) { + print x[1], x[2] +} |