Make CheckScopeChainValidity local to jsobj.cpp. No bug#, rs=gal on IRC.

This commit is contained in:
Jason Orendorff 2010-07-29 16:25:06 -05:00
parent 90eb236531
commit 7947f2514c
2 changed files with 3 additions and 9 deletions

View File

@ -911,8 +911,8 @@ js_CheckPrincipalsAccess(JSContext *cx, JSObject *scopeobj,
return JS_TRUE;
}
JSObject *
js_CheckScopeChainValidity(JSContext *cx, JSObject *scopeobj, const char *caller)
static JSObject *
CheckScopeChainValidity(JSContext *cx, JSObject *scopeobj, const char *caller)
{
JSObject *inner;
@ -1110,7 +1110,7 @@ obj_eval(JSContext *cx, uintN argc, Value *vp)
#endif
/* Ensure we compile this eval with the right object in the scope chain. */
JSObject *result = js_CheckScopeChainValidity(cx, scopeobj, js_eval_str);
JSObject *result = CheckScopeChainValidity(cx, scopeobj, js_eval_str);
JS_ASSERT_IF(result, result == scopeobj);
if (!result)
return JS_FALSE;

View File

@ -1298,12 +1298,6 @@ js_GetReservedSlot(JSContext *cx, JSObject *obj, uint32 index, js::Value *vp);
extern bool
js_SetReservedSlot(JSContext *cx, JSObject *obj, uint32 index, const js::Value &v);
/*
* Precondition: obj must be locked.
*/
extern JSObject *
js_CheckScopeChainValidity(JSContext *cx, JSObject *scopeobj, const char *caller);
extern JSBool
js_CheckPrincipalsAccess(JSContext *cx, JSObject *scopeobj,
JSPrincipals *principals, JSAtom *caller);