blob: cd8fd051cfad168f6d868042ac12edce11849115 [file] [log] [blame]
mark.lam@apple.comd0ac5b22013-09-10 16:54:23 +00001<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
2<html>
3<head>
4<script src="../resources/js-test-pre.js"></script>
5</head>
6<body>
7<script>
8
9 description(
10 "This test checks that toString() round-trip on a function that has a else clause directly \
11 followed by an else clause puts whitespace between the two on decompilation."
12 );
13
14
15 function testTryElse() { if (x) {} else try {} finally {} }
16
17 unevalf = function(x) { return '(' + x.toString() + ')'; };
18
19 // Test round trip.
20 shouldBe("unevalf(eval(unevalf(testTryElse)))", "unevalf(testTryElse)");
21</script>
22<script src="../resources/js-test-post.js"></script>
23</body>
24</html>