Sign in
webkit
/
WebKit
/
cdf72f0d7b69095eac98e4559cae6b681946d5d4
/
.
/
JSTests
/
es6
/
proper_tail_calls_tail_call_optimisation_direct_recursion.js
blob: f5d20ac84fd1b67b1364c7977a04bacf2b4345fa [
file
] [
log
] [
blame
]
function
test
()
{
"use strict"
;
return
(
function
f
(
n
){
if
(
n
<=
0
)
{
return
"foo"
;
}
return
f
(
n
-
1
);
}(
1e6
))
===
"foo"
;
}
if
(!
test
())
throw
new
Error
(
"Test failed"
);