From eab96aab0834f21954b5d6aa6366bcfb348ed811 Mon Sep 17 00:00:00 2001 From: Leon Clarke Date: Wed, 27 Jan 2010 16:31:12 +0000 Subject: Revert "Pull from svn bleeding_edge@3716" This reverts commit 888f6729be6a6f6fbe246cb5a9f122e2dbe455b7. (Waiting until v8 issue 554101 is in v8 rather than patching it straight into android) --- src/runtime.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src/runtime.js') diff --git a/src/runtime.js b/src/runtime.js index c4c855eb..ce2f197f 100644 --- a/src/runtime.js +++ b/src/runtime.js @@ -541,9 +541,7 @@ function ToObject(x) { if (IS_STRING(x)) return new $String(x); if (IS_NUMBER(x)) return new $Number(x); if (IS_BOOLEAN(x)) return new $Boolean(x); - if (IS_NULL_OR_UNDEFINED(x) && !IS_UNDETECTABLE(x)) { - throw %MakeTypeError('null_to_object', []); - } + if (x == null) throw %MakeTypeError('null_to_object', []); return x; } -- cgit v1.2.3