From 9cd118ca3d3e9882e4ecb14b153aa05cb070b453 Mon Sep 17 00:00:00 2001 From: Mark Jaquith Date: Fri, 25 Oct 2013 16:28:15 -0400 Subject: Add a unit test for issue-126 Add a unit test to test to test for aggressive parenthesis removal that causes functional changes. --- test/compress/issue-126.js | 2 ++ 1 file changed, 2 insertions(+) (limited to 'test') diff --git a/test/compress/issue-126.js b/test/compress/issue-126.js index 1e654941..7a597b87 100644 --- a/test/compress/issue-126.js +++ b/test/compress/issue-126.js @@ -10,6 +10,7 @@ concatenate_rhs_strings: { foo(bar() + 123 + "Hello" + "World" + ("Foo" + "Bar")); foo("Foo" + "Bar" + bar() + 123 + "Hello" + "World" + ("Foo" + "Bar")); foo("Hello" + bar() + 123 + "World"); + foo(bar() + 'Foo' + (10 + parseInt('10'))); } expect: { foo(bar() + 123 + "HelloWorld"); @@ -18,5 +19,6 @@ concatenate_rhs_strings: { foo(bar() + 123 + "HelloWorldFooBar"); foo("FooBar" + bar() + "123HelloWorldFooBar"); foo("Hello" + bar() + "123World"); + foo(bar() + 'Foo' + (10 + parseInt('10'))); } } -- cgit v1.2.3