accept a context in extendNative() methods

This commit is contained in:
Sami Samhuri 2011-11-05 16:08:00 -07:00
parent 59e6566d51
commit 8b5841587f
3 changed files with 6 additions and 6 deletions

View file

@ -3,8 +3,8 @@
exports.Range = Range;
exports.extendNative = function() {
global.Range = Range;
exports.extendNative = function(context) {
context.Range = Range;
};
function Range(start, length) {

View file

@ -4,8 +4,8 @@
// readable string representations of values
exports.repr = repr;
exports.extendNative = function() {
global.repr = repr;
exports.extendNative = function(context) {
context.repr = repr;
};
function repr(x) {

View file

@ -3,8 +3,8 @@
exports.Set = Set;
exports.extendNative = function() {
global.Set = Set;
exports.extendNative = function(context) {
context.Set = Set;
};
var ownProps = Object.getOwnPropertyNames;