public
/
UglifyJS.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
36c28e0
)
Avoid sequencesize for more than 2000 statements.
author
Mihai Bazon
<mihai.bazon@gmail.com>
Sun, 22 Mar 2015 10:51:15 +0000
(12:51 +0200)
committer
Mihai Bazon
<mihai.bazon@gmail.com>
Sun, 22 Mar 2015 10:51:15 +0000
(12:51 +0200)
It hardly saves any bytes for a sequence so long, and it risks blowing the
stack with the recursive Seq functions.
Ref #414
lib/compress.js
patch
|
blob
|
history
diff --git
a/lib/compress.js
b/lib/compress.js
index
17bebf7
..
b50e7cf
100644
(file)
--- a/
lib/compress.js
+++ b/
lib/compress.js
@@
-479,7
+479,7
@@
merge(Compressor.prototype, {
};
function sequencesize(statements, compressor) {
- if (statements.length < 2) return statements;
+ if (statements.length < 2
|| statements.length > 2000
) return statements;
var seq = [], ret = [];
function push_seq() {
seq = AST_Seq.from_array(seq);