projects
/
platform
/
upstream
/
nodejs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c3a9733
)
startup: move `EventEmitter` closer to the lookup
author
Maciej Małecki
<maciej.malecki@notimplemented.org>
Sat, 18 Feb 2012 15:45:22 +0000
(16:45 +0100)
committer
Ben Noordhuis
<info@bnoordhuis.nl>
Mon, 20 Feb 2012 15:04:44 +0000
(16:04 +0100)
This makes startup faster by ~0.2 ms on my computer.
src/node.js
patch
|
blob
|
history
diff --git
a/src/node.js
b/src/node.js
index 2cd797fea3b8b62650603cb96603b0c3d5f6ce10..4a11b5c52fa835e7e343930b67df828b0f848605 100644
(file)
--- a/
src/node.js
+++ b/
src/node.js
@@
-27,10
+27,8
@@
(function(process) {
global = this;
- var EventEmitter;
-
function startup() {
- EventEmitter = NativeModule.require('events').EventEmitter;
+
var
EventEmitter = NativeModule.require('events').EventEmitter;
process.__proto__ = EventEmitter.prototype;
process.EventEmitter = EventEmitter; // process.EventEmitter is deprecated