Skip to content

Commit

Permalink
Implementation.
Browse files Browse the repository at this point in the history
  • Loading branch information
ljharb committed Dec 15, 2014
1 parent 6298e7c commit 7d5e297
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
'use strict';

var makeGeneratorFunction = function () {
return Function('return function* () { var x = yield; return x || 42; }')();
};
var generatorFunc;
try { generatorFunc = makeGeneratorFunction(); } catch (e) {}

module.exports = generatorFunc;


0 comments on commit 7d5e297

Please sign in to comment.