Give up evaluating (unary-prefix '-' 0)
Close #117 ------ JS, WHY YOU SUCK SO BADLY? ;-(
This commit is contained in:
parent
fdf8b5eb71
commit
f36e4e9a78
|
|
@ -628,7 +628,10 @@ merge(Compressor.prototype, {
|
|||
case "typeof": return typeof ev(e);
|
||||
case "void": return void ev(e);
|
||||
case "~": return ~ev(e);
|
||||
case "-": return -ev(e);
|
||||
case "-":
|
||||
e = ev(e);
|
||||
if (e === 0) throw def;
|
||||
return -e;
|
||||
case "+": return +ev(e);
|
||||
}
|
||||
throw def;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user