ok = OBJ_LOOKUP_PROPERTY(cx, obj, ATOM_TO_JSID(atom), &pobj, &prop);
ok = js_LookupPropertyWithFlags(cx, obj, ATOM_TO_JSID(atom), JSLOOKUP_HIDDEN, &pobj, &prop);
js_LookupCompileTimeConstant(JSContext *cx, JSCodeGenerator *cg, JSAtom *atom,                             jsval *vp){    JSBool ok;    JSStackFrame *fp;    JSAtomListElement *ale;    JSObject *obj, *pobj;    JSProperty *prop;    uintN attrs;    /*     * fp chases cg down the stack, but only until we reach the outermost cg.     * This enables propagating consts from top-level into switch cases in a     * function compiled along with the top-level script.  All stack frames     * with matching code generators should be flagged with JSFRAME_COMPILING;     * we check sanity here.     */    *vp = JSVAL_VOID;    ok = JS_TRUE;    fp = cx->fp;    do {        JS_ASSERT(fp->flags & JSFRAME_COMPILING);        obj = fp->varobj;        if (obj == fp->scopeChain &&            !js_InWithStatement(&cg->treeContext) &&            !js_InCatchBlock(&cg->treeContext, atom)) {            ATOM_LIST_SEARCH(ale, &cg->constList, atom);            if (ale) {                *vp = ALE_VALUE(ale);                return JS_TRUE;            }            /*             * Try looking in the variable object for a direct property that             * is readonly and permanent.  We know such a property can't be             * shadowed by another property on obj's prototype chain, or a             * with object or catch variable; nor can prop's value be changed,             * nor can prop be deleted.             */            prop = NULL;            ok = OBJ_LOOKUP_PROPERTY(cx, obj, ATOM_TO_JSID(atom), &pobj, &prop);            if (ok) {                if (pobj == obj &&                    (fp->flags & (JSFRAME_EVAL | JSFRAME_COMPILE_N_GO))) {                    /*                     * We're compiling code that will be executed immediately,                     * not re-executed against a different scope chain and/or                     * variable object.  Therefore we can get constant values                     * from our variable object here.                     */                    ok = OBJ_GET_ATTRIBUTES(cx, obj, ATOM_TO_JSID(atom), prop,                                            &attrs);                    if (ok && !(~attrs & (JSPROP_READONLY | JSPROP_PERMANENT)))                        ok = OBJ_GET_PROPERTY(cx, obj, ATOM_TO_JSID(atom), vp);                }                if (prop)                    OBJ_DROP_PROPERTY(cx, pobj, prop);            }            if (!ok || prop)                break;        }        fp = fp->down;    } while ((cg = cg->parent) != NULL);