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:
f3d3641
)
Closes GH-232 Make the repl's global the right thing
author
isaacs
<i@izs.me>
Wed, 16 Feb 2011 23:40:53 +0000
(15:40 -0800)
committer
Ryan Dahl
<ry@tinyclouds.org>
Mon, 28 Feb 2011 01:13:52 +0000
(17:13 -0800)
lib/repl.js
patch
|
blob
|
history
diff --git
a/lib/repl.js
b/lib/repl.js
index
4c769e7
..
7e42ac9
100644
(file)
--- a/
lib/repl.js
+++ b/
lib/repl.js
@@
-45,6
+45,8
@@
function resetContext() {
for (var i in global) context[i] = global[i];
context.module = module;
context.require = require;
+ context.global = context;
+ context.global.global = context;
for (var i in require.cache) delete require.cache[i];
}