aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorMihai Bazon <mihai@bazon.net>2013-08-07 12:04:58 +0300
committerMihai Bazon <mihai@bazon.net>2013-08-07 12:04:58 +0300
commit4c4dc2137cc256bb1e7a3827b4c96c95be42782e (patch)
treee77085a920deb5aa11adab159174dc1952649a02 /test
parent4aa4b3e69493097c6674ad79a2300a64f77842cd (diff)
downloadtracifyjs-4c4dc2137cc256bb1e7a3827b4c96c95be42782e.tar.gz
tracifyjs-4c4dc2137cc256bb1e7a3827b4c96c95be42782e.zip
Don't drop unused setter argument.
Fix #257
Diffstat (limited to 'test')
-rw-r--r--test/compress/drop-unused.js24
1 files changed, 24 insertions, 0 deletions
diff --git a/test/compress/drop-unused.js b/test/compress/drop-unused.js
index bf5cd296..406ce9e6 100644
--- a/test/compress/drop-unused.js
+++ b/test/compress/drop-unused.js
@@ -95,3 +95,27 @@ unused_circular_references_3: {
}
}
}
+
+unused_keep_setter_arg: {
+ options = { unused: true };
+ input: {
+ var x = {
+ _foo: null,
+ set foo(val) {
+ },
+ get foo() {
+ return this._foo;
+ }
+ }
+ }
+ expect: {
+ var x = {
+ _foo: null,
+ set foo(val) {
+ },
+ get foo() {
+ return this._foo;
+ }
+ }
+ }
+}