From e9a97cbf8b6877a84305a00e79208451e28c0332 Mon Sep 17 00:00:00 2001 From: Steve Fink Date: Fri, 11 Oct 2013 22:02:24 -0700 Subject: [PATCH] Bug 925582 - Handlify ParseContext::define, r=terrence --HG-- extra : rebase_source : 603d1010716d78c4fdc0b52285f02a69736de86b --- js/src/frontend/Parser.cpp | 4 ++-- js/src/frontend/Parser.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/js/src/frontend/Parser.cpp b/js/src/frontend/Parser.cpp index 70f83365514..050730e6c7f 100644 --- a/js/src/frontend/Parser.cpp +++ b/js/src/frontend/Parser.cpp @@ -94,7 +94,7 @@ PushStatementPC(ParseContext *pc, StmtInfoPC *stmt, StmtType type) template <> bool ParseContext::define(TokenStream &ts, - PropertyName *name, ParseNode *pn, Definition::Kind kind) + HandlePropertyName name, ParseNode *pn, Definition::Kind kind) { JS_ASSERT(!pn->isUsed()); JS_ASSERT_IF(pn->isDefn(), pn->isPlaceholder()); @@ -186,7 +186,7 @@ ParseContext::define(TokenStream &ts, template <> bool -ParseContext::define(TokenStream &ts, PropertyName *name, Node pn, +ParseContext::define(TokenStream &ts, HandlePropertyName name, Node pn, Definition::Kind kind) { JS_ASSERT(!decls_.lookupFirst(name)); diff --git a/js/src/frontend/Parser.h b/js/src/frontend/Parser.h index 19cdfd594c3..08c9d2d5e46 100644 --- a/js/src/frontend/Parser.h +++ b/js/src/frontend/Parser.h @@ -167,7 +167,7 @@ struct ParseContext : public GenericParseContext * 'pn' if they are in the scope of 'pn'. * + Pre-existing placeholders in the scope of 'pn' have been removed. */ - bool define(TokenStream &ts, PropertyName *name, Node pn, Definition::Kind); + bool define(TokenStream &ts, HandlePropertyName name, Node pn, Definition::Kind); /* * Let definitions may shadow same-named definitions in enclosing scopes.