diff options
author | Alex Lam S.L <alexlamsl@gmail.com> | 2021-02-07 22:44:20 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-02-08 06:44:20 +0800 |
commit | fd4caf7a9cbfaa482d8cc77d2bc8cd00e8bc256a (patch) | |
tree | 75e5f2eedf3dbf809d76e419ab03d4dc62363a79 /lib/transform.js | |
parent | c44b6399c30b043f9bf687ce9b44458abc211d80 (diff) | |
download | tracifyjs-fd4caf7a9cbfaa482d8cc77d2bc8cd00e8bc256a.tar.gz tracifyjs-fd4caf7a9cbfaa482d8cc77d2bc8cd00e8bc256a.zip |
support generator functions (#4620)
Diffstat (limited to 'lib/transform.js')
-rw-r--r-- | lib/transform.js | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/transform.js b/lib/transform.js index b84bf0b9..ede6e254 100644 --- a/lib/transform.js +++ b/lib/transform.js @@ -157,6 +157,9 @@ TreeTransformer.prototype = new TreeWalker; DEF(AST_Await, function(self, tw) { self.expression = self.expression.transform(tw); }); + DEF(AST_Yield, function(self, tw) { + if (self.expression) self.expression = self.expression.transform(tw); + }); DEF(AST_Dot, function(self, tw) { self.expression = self.expression.transform(tw); }); |