Sign in
webkit
/
WebKit
/
60c3f717a9141a0f8afd6e8437d26c6404e4424c
/
.
/
LayoutTests
/
js
/
script-tests
/
dfg-negative-array-index.js
blob: 781f0bc1a65ff51cff8ff0431c4515703a424a8a [
file
] [
log
] [
blame
]
description
(
"Tests that storing into a negative array index works right."
);
function
foo
(
a
,
i
)
{
a
[
i
]
=
42
;
}
for
(
var
i
=
0
;
i
<
100
;
++
i
)
{
var
array
=
[];
foo
(
array
,
-
1
);
shouldBe
(
"array[-1]"
,
"42"
);
}