Bug 784295 - Part 1: Compile self-hosted JS in strict mode (in DEBUG builds). r=till

This commit is contained in:
Chris Peterson 2013-11-24 21:56:20 -08:00
parent 725d9a07c7
commit 94e96bb8cb
2 changed files with 6 additions and 1 deletions

View File

@ -664,7 +664,7 @@ function X4ProtoString(type) {
assert(false, "Unhandled type constant");
}
X4LaneStrings = ["x", "y", "z", "w"];
var X4LaneStrings = ["x", "y", "z", "w"];
// Generalized handler for the various properties for accessing a
// single lane of an X4 vector value. Note that this is the slow path;

View File

@ -779,6 +779,11 @@ JSRuntime::initSelfHosting(JSContext *cx)
options.setCanLazilyParse(false);
options.setSourcePolicy(CompileOptions::NO_SOURCE);
options.setVersion(JSVERSION_LATEST);
options.werrorOption = true;
#ifdef DEBUG
options.strictOption = true;
#endif
/*
* Set a temporary error reporter printing to stderr because it is too