aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/compress/concat-strings.js50
1 files changed, 50 insertions, 0 deletions
diff --git a/test/compress/concat-strings.js b/test/compress/concat-strings.js
index d2503c6d..2f99375c 100644
--- a/test/compress/concat-strings.js
+++ b/test/compress/concat-strings.js
@@ -164,3 +164,53 @@ concat_6: {
);
}
}
+
+concat_7: {
+ input: {
+ console.log(
+ "" + 1,
+ "" + "1",
+ "" + 1 + 2,
+ "" + 1 + "2",
+ "" + "1" + 2,
+ "" + "1" + "2",
+ "" + (x += "foo")
+ );
+ }
+ expect: {
+ console.log(
+ "" + 1,
+ "1",
+ "" + 1 + 2,
+ 1 + "2",
+ "1" + 2,
+ "1" + "2",
+ x += "foo"
+ );
+ }
+}
+
+concat_8: {
+ input: {
+ console.log(
+ 1 + "",
+ "1" + "",
+ 1 + 2 + "",
+ 1 + "2" + "",
+ "1" + 2 + "",
+ "1" + "2" + "",
+ (x += "foo") + ""
+ );
+ }
+ expect: {
+ console.log(
+ 1 + "",
+ "1",
+ 1 + 2 + "",
+ 1 + "2",
+ "1" + 2,
+ "1" + "2",
+ x += "foo"
+ );
+ }
+}