Commit 5a82d8e3 authored by sgjesse@chromium.org's avatar sgjesse@chromium.org

Remove unused parameter.

Review URL: http://codereview.chromium.org/113523

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@1990 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent a77d81c5
......@@ -267,7 +267,6 @@ Handle<JSFunction> Compiler::Compile(Handle<String> source,
Handle<JSFunction> Compiler::CompileEval(Handle<String> source,
Handle<Context> context,
int line_offset,
bool is_global,
bool is_json) {
int source_length = source->length();
......@@ -287,7 +286,6 @@ Handle<JSFunction> Compiler::CompileEval(Handle<String> source,
if (result.is_null()) {
// Create a script object describing the script to be compiled.
Handle<Script> script = Factory::NewScript(source);
script->set_line_offset(Smi::FromInt(line_offset));
result = MakeFunction(is_global,
true,
is_json,
......
......@@ -61,7 +61,6 @@ class Compiler : public AllStatic {
// Compile a String source within a context for Eval.
static Handle<JSFunction> CompileEval(Handle<String> source,
Handle<Context> context,
int line_offset,
bool is_global,
bool is_json);
......
......@@ -1171,7 +1171,7 @@ DebugCommandProcessor.prototype.processDebugJSONRequest = function(json_request)
try {
try {
// Convert the JSON string to an object.
request = %CompileString('(' + json_request + ')', 0, false)();
request = %CompileString('(' + json_request + ')', false)();
// Create an initial response.
response = this.createResponse(request);
......
......@@ -29,7 +29,7 @@ var $JSON = global.JSON;
function ParseJSONUnfiltered(text) {
var s = $String(text);
var f = %CompileString("(" + text + ")", -1, true);
var f = %CompileString("(" + text + ")", true);
return f();
}
......
......@@ -4888,16 +4888,14 @@ static Object* Runtime_GlobalReceiver(Arguments args) {
static Object* Runtime_CompileString(Arguments args) {
HandleScope scope;
ASSERT_EQ(3, args.length());
ASSERT_EQ(2, args.length());
CONVERT_ARG_CHECKED(String, source, 0);
CONVERT_ARG_CHECKED(Smi, line_offset, 1);
CONVERT_ARG_CHECKED(Oddball, is_json, 2)
CONVERT_ARG_CHECKED(Oddball, is_json, 1)
// Compile source string in the global context.
Handle<Context> context(Top::context()->global_context());
Handle<JSFunction> boilerplate = Compiler::CompileEval(source,
context,
line_offset->value(),
true,
is_json->IsTrue());
if (boilerplate.is_null()) return Failure::Exception();
......@@ -4924,7 +4922,7 @@ static Object* CompileDirectEval(Handle<String> source) {
// Compile source string in the current context.
Handle<JSFunction> boilerplate =
Compiler::CompileEval(source, context, 0, is_global, false);
Compiler::CompileEval(source, context, is_global, false);
if (boilerplate.is_null()) return Failure::Exception();
Handle<JSFunction> fun =
Factory::NewFunctionFromBoilerplate(boilerplate, context);
......@@ -6557,7 +6555,6 @@ static Object* Runtime_DebugEvaluate(Arguments args) {
Handle<JSFunction> boilerplate =
Compiler::CompileEval(function_source,
context,
0,
context->IsGlobalContext(),
false);
if (boilerplate.is_null()) return Failure::Exception();
......@@ -6619,7 +6616,6 @@ static Object* Runtime_DebugEvaluateGlobal(Arguments args) {
Handle<JSFunction> boilerplate =
Handle<JSFunction>(Compiler::CompileEval(source,
context,
0,
true,
false));
if (boilerplate.is_null()) return Failure::Exception();
......
......@@ -199,7 +199,7 @@ namespace v8 { namespace internal {
F(NumberIsFinite, 1) \
\
/* Globals */ \
F(CompileString, 3) \
F(CompileString, 2) \
F(GlobalPrint, 1) \
\
/* Eval */ \
......
......@@ -120,7 +120,7 @@ function GlobalEval(x) {
'be the global object from which eval originated');
}
var f = %CompileString(x, 0, false);
var f = %CompileString(x, false);
if (!IS_FUNCTION(f)) return f;
return f.call(this);
......@@ -131,7 +131,7 @@ function GlobalEval(x) {
function GlobalExecScript(expr, lang) {
// NOTE: We don't care about the character casing.
if (!lang || /javascript/i.test(lang)) {
var f = %CompileString(ToString(expr), 0, false);
var f = %CompileString(ToString(expr), false);
f.call(%GlobalReceiver(global));
}
return null;
......@@ -550,7 +550,7 @@ function NewFunction(arg1) { // length == 1
// The call to SetNewFunctionAttributes will ensure the prototype
// property of the resulting function is enumerable (ECMA262, 15.3.5.2).
var f = %CompileString(source, -1, false)();
var f = %CompileString(source, false)();
%FunctionSetName(f, "anonymous");
return %SetNewFunctionAttributes(f);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment