mirror of https://github.com/lukechilds/node.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
12 lines
385 B
12 lines
385 B
11 years ago
|
// eeeeeevvvvviiiiiiillllll
|
||
|
// more evil than monkey-patching the native builtin?
|
||
|
// Not sure.
|
||
|
|
||
|
var mod = require("module")
|
||
|
var pre = '(function (exports, require, module, __filename, __dirname) { '
|
||
|
var post = '});'
|
||
|
var src = pre + process.binding('natives').fs + post
|
||
|
var vm = require('vm')
|
||
|
var fn = vm.runInThisContext(src)
|
||
|
return fn(exports, require, module, __filename, __dirname)
|