michael@0: michael@0: // TI does not account for GETELEM accessing strings, so the GETELEM PIC must michael@0: // update type constraints according to generated stubs. michael@0: function foo(a, b) { michael@0: for (var j = 0; j < 5; j++) michael@0: a[b[j]] + " what"; michael@0: } michael@0: var a = {a:"zero", b:"one", c:"two", d:"three", e:"four"}; michael@0: var b = ["a", "b", "c", "d", "e"]; michael@0: foo(a, b); michael@0: foo(a, b); michael@0: a.e = 4; michael@0: foo(a, b);