Avoid repeating impure (template) literals when desugaring **= (#4403) (#4672)

This commit is contained in:
Moti Zilberman
2016-10-05 12:10:12 +03:00
committed by Daniel Tschinder
parent 9e17aaf043
commit f5b5d8f337
4 changed files with 9 additions and 1 deletions

View File

@@ -0,0 +1,2 @@
var a, b;
a[`${b++}`] **= 1;

View File

@@ -0,0 +1,3 @@
var a, b;
var _ref = `${ b++ }`;
a[_ref] = Math.pow(a[_ref], 1)

View File

@@ -0,0 +1,3 @@
{
"plugins": ["transform-exponentiation-operator"]
}