summaryrefslogtreecommitdiff
path: root/deps/v8/src/json.js
diff options
context:
space:
mode:
authorRyan Dahl <ry@tinyclouds.org>2011-09-15 09:41:08 -0700
committerRyan Dahl <ry@tinyclouds.org>2011-09-15 09:42:06 -0700
commit1b15af9dd2bf4adb7a2e73ae17a12e2e98a88f72 (patch)
treefeede6d06b8c99b92e29a9fdcf0e9ade05b981d0 /deps/v8/src/json.js
parentf8b90946aec53b453d82dd66a4d812ec86487629 (diff)
downloadnode-new-1b15af9dd2bf4adb7a2e73ae17a12e2e98a88f72.tar.gz
Upgrade V8 to 3.6.4
Diffstat (limited to 'deps/v8/src/json.js')
-rw-r--r--deps/v8/src/json.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/deps/v8/src/json.js b/deps/v8/src/json.js
index a491bcc151..deba126212 100644
--- a/deps/v8/src/json.js
+++ b/deps/v8/src/json.js
@@ -54,7 +54,7 @@ function Revive(holder, name, reviver) {
function JSONParse(text, reviver) {
var unfiltered = %ParseJson(TO_STRING_INLINE(text));
- if (IS_FUNCTION(reviver)) {
+ if (IS_SPEC_FUNCTION(reviver)) {
return Revive({'': unfiltered}, '', reviver);
} else {
return unfiltered;
@@ -143,11 +143,11 @@ function JSONSerialize(key, holder, replacer, stack, indent, gap) {
var value = holder[key];
if (IS_SPEC_OBJECT(value)) {
var toJSON = value.toJSON;
- if (IS_FUNCTION(toJSON)) {
+ if (IS_SPEC_FUNCTION(toJSON)) {
value = %_CallFunction(value, key, toJSON);
}
}
- if (IS_FUNCTION(replacer)) {
+ if (IS_SPEC_FUNCTION(replacer)) {
value = %_CallFunction(holder, key, value, replacer);
}
if (IS_STRING(value)) {
@@ -273,7 +273,7 @@ function BasicSerializeObject(value, stack, builder) {
function BasicJSONSerialize(key, value, stack, builder) {
if (IS_SPEC_OBJECT(value)) {
var toJSON = value.toJSON;
- if (IS_FUNCTION(toJSON)) {
+ if (IS_SPEC_FUNCTION(toJSON)) {
value = %_CallFunction(value, ToString(key), toJSON);
}
}