 				exec(
 					{
 						"JSON_FUNCTION_PREFIX": JSON_FUNCTION_PREFIX,
+						"JSON_EXTENSIONS": JSON_EXTENSIONS,
 						"JSON_REPLACER": JSON_REPLACER,
 						"JSON_REVIVER": JSON_REVIVER,
 						"JSON_SUFFIX": JSON_SUFFIX,

					_jsonLookup[id] = value;
				}
				_needsReviving = true;
				return id;
			}
			if (value is Number && !isFinite(value as Number))
			{
				_needsReviving = true;
				return value + JSON_SUFFIX;
			}
			return value;
		}
		

					"            value[JSON_FUNCTION_PREFIX] = id;",
					"            lookup[id] = value;",
					"        }",
					"        value = value[JSON_FUNCTION_PREFIX];",
					"    }",
					"    else if (typeof value === 'number' && !isFinite(value))",
					"        value = value + JSON_SUFFIX;",
					"    else if (Array.isArray(value) && !(value instanceof Array))",
					"        value = Array.prototype.slice.call(value);",
					"    for (var i in extensions)",
					"        if (typeof extensions[i] === 'object' && typeof extensions[i].replacer === 'function')",
					"            value = extensions[i].replacer.call(flash, key, value);",
					"    return value;",
					"};",
					
					"flash[JSON_REVIVER] = function(key, value) {",
					"    if (typeof value === 'string') {",
					"        if (lookup.hasOwnProperty(value))",
					"            value = lookup[value];",
					"        else if (value.substr(0, JSON_FUNCTION_PREFIX.length) == JSON_FUNCTION_PREFIX) {",
					"            var id = value;",
					"            var func = function() {",
					"                var params = Array.prototype.slice.call(arguments);",
					"                var paramsJson = JSON.stringify(params, flash[JSON_REPLACER]);",
					"                var resultJson = flash[JSON_CALL](id, paramsJson);",
					"                return JSON.parse(resultJson, flash[JSON_REVIVER]);",
					"            };",
					"            func[JSON_FUNCTION_PREFIX] = id;",
					"            value = lookup[id] = func;",
					"        }",
					"    }",
					"    for (var i in extensions)",
					"        if (typeof extensions[i] === 'object' && typeof extensions[i].reviver === 'function')",
					"            value = extensions[i].reviver.call(flash, key, value);",
					"    return value;",
					"};"
				);
			}
		}
		
		/*var replace = weave._jsonReplacer, revive = weave._jsonReviver;
		weave._jsonReplacer = (k, v) => {
		var r = replace.call(weave, k, v);
		console.log('replace', k, v, r);
		return r;
		}
		weave._jsonReviver = (k, v) => {
		var r = revive.call(weave, k, v);
		console.log('revive', k, v, r);
		return r;
		}
		JSON.stringify({x: Math.round}, weave._jsonReplacer)
		//*/
		
		/**
		 * Handles a JavaScript request.
