[Pkg-javascript-commits] [uglifyjs] 52/190: more tests for `return undefined` optimization

Antonio Terceiro terceiro at moszumanska.debian.org
Sun Aug 7 23:17:12 UTC 2016


This is an automated email from the git hooks/post-receive script.

terceiro pushed a commit to annotated tag upstream/2.7.0
in repository uglifyjs.

commit 841a661071a70d1b1c222e7c0f35fb05c6b7b041
Author: kzc <zaxxon2011 at gmail.com>
Date:   Wed Oct 28 13:41:41 2015 -0400

    more tests for `return undefined` optimization
---
 test/compress/return_undefined.js | 36 ++++++++++++++++++++++++++++++++++++
 1 file changed, 36 insertions(+)

diff --git a/test/compress/return_undefined.js b/test/compress/return_undefined.js
index be79d89..b1195a7 100644
--- a/test/compress/return_undefined.js
+++ b/test/compress/return_undefined.js
@@ -69,6 +69,15 @@ return_void_0_true: {
             bar(b);
             return undefined;
         }
+        function f10() {
+            return false;
+        }
+        function f11() {
+            return null;
+        }
+        function f12() {
+            return 0;
+        }
     }
     expect: {
         function f0() {}
@@ -103,6 +112,15 @@ return_void_0_true: {
             foo(a);
             bar(b);
         }
+        function f10() {
+            return !1;
+        }
+        function f11() {
+            return null;
+        }
+        function f12() {
+            return 0;
+        }
     }
 }
 
@@ -177,6 +195,15 @@ return_void_0_false: {
             bar(b);
             return undefined;
         }
+        function f10() {
+            return false;
+        }
+        function f11() {
+            return null;
+        }
+        function f12() {
+            return 0;
+        }
     }
     expect: {
         function f0() {
@@ -224,6 +251,15 @@ return_void_0_false: {
             bar(b);
             return void 0;
         }
+        function f10() {
+            return !1;
+        }
+        function f11() {
+            return null;
+        }
+        function f12() {
+            return 0;
+        }
     }
 }
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/uglifyjs.git



More information about the Pkg-javascript-commits mailing list