Back out b70659aca040, burning XPCShell tests. (no_r=me)

This commit is contained in:
Chris Leary 2010-09-23 16:48:35 -07:00
parent ae80e2268b
commit 56196fb6ff
5 changed files with 2 additions and 49 deletions

View File

@ -4807,16 +4807,6 @@ JS_EvaluateScriptForPrincipals(JSContext *cx, JSObject *obj, JSPrincipals *princ
return ok;
}
JS_PUBLIC_API(JSBool)
JS_EvaluateScriptForPrincipalsVersion(JSContext *cx, JSObject *obj, JSPrincipals *principals,
const char *bytes, uintN nbytes,
const char *filename, uintN lineno, jsval *rval, JSVersion version)
{
AutoVersionAPI avi(cx, version);
return JS_EvaluateScriptForPrincipals(cx, obj, principals, bytes, nbytes, filename, lineno,
rval);
}
JS_PUBLIC_API(JSBool)
JS_EvaluateScript(JSContext *cx, JSObject *obj, const char *bytes, uintN nbytes,
const char *filename, uintN lineno, jsval *rval)

View File

@ -2582,13 +2582,6 @@ JS_EvaluateScriptForPrincipals(JSContext *cx, JSObject *obj,
const char *filename, uintN lineno,
jsval *rval);
extern JS_PUBLIC_API(JSBool)
JS_EvaluateScriptForPrincipalsVersion(JSContext *cx, JSObject *obj,
JSPrincipals *principals,
const char *bytes, uintN length,
const char *filename, uintN lineno,
jsval *rval, JSVersion version);
extern JS_PUBLIC_API(JSBool)
JS_EvaluateUCScript(JSContext *cx, JSObject *obj,
const jschar *chars, uintN length,

View File

@ -60,8 +60,6 @@
#include "jsapi.h"
#include "jsdbgapi.h"
#include "jsobj.h"
#include "jsscript.h"
#include "jscntxt.h"
#include "mozilla/FunctionTimer.h"
@ -235,7 +233,6 @@ mozJSSubScriptLoader::LoadSubScript (const PRUnichar * aURL
JSStackFrame* frame = nsnull;
JSScript* script = nsnull;
JSVersion version;
// Figure out who's calling us
do
@ -351,12 +348,8 @@ mozJSSubScriptLoader::LoadSubScript (const PRUnichar * aURL
* exceptions, including the source/line number */
er = JS_SetErrorReporter (cx, mozJSLoaderErrorReporter);
version = script->getVersion();
version = JSVersion((version & js::VersionFlags::MASK)
| (version & js::VersionFlags::HAS_XML));
ok = JS_EvaluateScriptForPrincipalsVersion(cx, target_obj, jsPrincipals,
buf, len, uriStr.get(), 1,
rval, version);
ok = JS_EvaluateScriptForPrincipals (cx, target_obj, jsPrincipals,
buf, len, uriStr.get(), 1, rval);
/* repent for our evil deeds */
JS_SetErrorReporter (cx, er);

View File

@ -1,4 +0,0 @@
/* Some constructs that require a high default version number. */
let x = 12;
function simpleGen() { yield 12; }
var e4xy = <html><title>Huzzah!</title></html>

View File

@ -1,19 +0,0 @@
const Cc = Components.classes;
const Ci = Components.interfaces;
function run_test() {
var file = do_get_file("bug596580_versioned.js");
var ios = Cc["@mozilla.org/network/io-service;1"]
.getService(Ci.nsIIOService);
var uri = ios.newFileURI(file);
var scriptLoader = Cc["@mozilla.org/moz/jssubscript-loader;1"]
.getService(Ci.mozIJSSubScriptLoader);
scriptLoader.loadSubScript(uri.spec);
version(150)
try {
scriptLoader.loadSubScript(uri.spec);
throw new Exception("Subscript should fail to load.");
} catch (e if e instanceof SyntaxError) {
// Okay.
}
}