PageRenderTime 16ms CodeModel.GetById 6ms app.highlight 5ms RepoModel.GetById 1ms app.codeStats 1ms

/js/src/jit-test/tests/jaeger/getelem-sanity-int-2.js

http://github.com/zpao/v8monkey
JavaScript | 12 lines | 10 code | 1 blank | 1 comment | 2 complexity | fa08e5aba38d0789bd8bc6b249cd70b1 MD5 | raw file
 1var arr = ['this', 'works', 'for', 'me'];
 2for (var i = 0; i < arr.length; ++i) {
 3    var result = arr[i];
 4    switch (i) {
 5      case 0: assertEq('this', result); break;
 6      case 1: assertEq('works', result); break;
 7      case 2: assertEq('for', result); break;
 8      case 3: assertEq('me', result); break;
 9    }
10}
11
12/* int32_t getelem for dense array. */