aboutsummaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
authorAlex Lam S.L <alexlamsl@gmail.com>2021-05-25 23:21:52 +0100
committerGitHub <noreply@github.com>2021-05-26 06:21:52 +0800
commit7caab39e261f1787f1a40fca3e7b6fd6ab21d824 (patch)
tree6a6baf28ee507a5474d23983d857147092dc5c7b /README.md
parenteff45eac0ee284a113d1b587263fcef8e397daa3 (diff)
downloadtracifyjs-7caab39e261f1787f1a40fca3e7b6fd6ab21d824.tar.gz
tracifyjs-7caab39e261f1787f1a40fca3e7b6fd6ab21d824.zip
fix corner case in `mangle` (#4966)
fixes #4965
Diffstat (limited to 'README.md')
-rw-r--r--README.md13
1 files changed, 13 insertions, 0 deletions
diff --git a/README.md b/README.md
index 760fac53..06b16551 100644
--- a/README.md
+++ b/README.md
@@ -1341,3 +1341,16 @@ To allow for better optimizations, the compiler makes various assumptions:
// Actual: "FAIL"
```
UglifyJS may modify the input which in turn may suppress those errors.
+- Earlier versions of JavaScript will throw `TypeError` with the following:
+ ```javascript
+ (function() {
+ {
+ const a = "foo";
+ }
+ {
+ const a = "bar";
+ }
+ })();
+ // TypeError: const 'a' has already been declared
+ ```
+ UglifyJS may modify the input which in turn may suppress those errors.