File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -124,11 +124,11 @@ function Plugin(babel) {
124124 ) ;
125125 }
126126 // Instruction Token: Yield with argument
127- function hzYieldArg ( argExp , delegate ) {
127+ function hzYieldArg ( argExp , delegate = false ) {
128128 const callExp = hzYield ( ) ;
129129 callExp . callee . property . name = "yieldValue" ;
130130 callExp . arguments [ 0 ] . properties [ 0 ] . value = argExp ;
131- callExp . arguments [ 1 ] = delegate ;
131+ callExp . arguments [ 1 ] = t . BooleanLiteral ( delegate ) ;
132132 return callExp ;
133133 }
134134 // Instruction Token: Spawn without arguments
@@ -503,6 +503,7 @@ function Plugin(babel) {
503503 exit : function ( path ) {
504504 if ( path . node . argument === null ) path . node . argument = hzYield ( ) ;
505505 else path . node . argument = hzYieldArg ( path . node . argument , path . node . delegate ) ;
506+ if ( path . node . delegate ) path . node . delegate = false ;
506507 }
507508 }
508509 } ;
You can’t perform that action at this time.
0 commit comments