Skip to content

Commit cdec97e

Browse files
committed
Adding UT
1 parent c119221 commit cdec97e

File tree

2 files changed

+29
-0
lines changed

2 files changed

+29
-0
lines changed

test/Optimizer/rlexe.xml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1477,6 +1477,12 @@
14771477
<compile-flags>-mic:1 -off:simplejit</compile-flags>
14781478
</default>
14791479
</test>
1480+
<test>
1481+
<default>
1482+
<files>test149.js</files>
1483+
<compile-flags>-mic:1 -off:simplejit -bgjit- -force:fixdataprops -lic:1</compile-flags>
1484+
</default>
1485+
</test>
14801486
<test>
14811487
<default>
14821488
<files>IsIn_ArrayNoMissingValues.js</files>

test/Optimizer/test149.js

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
//-------------------------------------------------------------------------------------------------------
2+
// Copyright (C) Microsoft. All rights reserved.
3+
// Licensed under the MIT license. See LICENSE.txt file in the project root for full license information.
4+
//-------------------------------------------------------------------------------------------------------
5+
6+
function makeArrayLength() {
7+
return 1;
8+
}
9+
var obj0 = {};
10+
var arrObj0 = {};
11+
var func3 = function () {
12+
arrObj0[1] = 1;
13+
return obj0.length;
14+
};
15+
16+
obj0.method0 = func3;
17+
var h = 1;
18+
obj0.length = makeArrayLength();
19+
var __loopvar1 = 1;
20+
do {
21+
h = obj0.method0(h);
22+
} while (obj0.method0() && __loopvar1++ < 10);
23+
print("passed");

0 commit comments

Comments
 (0)