Merge pull request #147 from koajs/delegate-next-bench

benchmark: use generator delegation
master
TJ Holowaychuk 2013-12-25 09:25:00 -08:00
commit b944b89df7
1 changed files with 2 additions and 2 deletions

View File

@ -10,14 +10,14 @@ console.log(' %s middleware', n);
while (n--) {
app.use(function *(next){
yield next;
yield *next;
});
}
var body = new Buffer('Hello World');
app.use(function *(next){
yield next;
yield *next;
this.body = body;
});