Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1605)

Unified Diff: src/scopes.h

Issue 173052: Fix uninitialized members (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/scopes.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/scopes.h
===================================================================
--- src/scopes.h (revision 2708)
+++ src/scopes.h (working copy)
@@ -93,7 +93,6 @@
GLOBAL_SCOPE // the top-level scope for a program or a top-level eval
};
- Scope();
Scope(Scope* outer_scope, Type type);
virtual ~Scope() { }
@@ -130,7 +129,7 @@
Variable* DeclareGlobal(Handle<String> name);
// Add a parameter to the parameter list. The parameter must have been
- // declared via Declare. The same parameter may occur more then once in
+ // declared via Declare. The same parameter may occur more than once in
// the parameter list; they must be added in source order, from left to
// right.
void AddParameter(Variable* var);
@@ -286,6 +285,8 @@
protected:
friend class ParserFactory;
+ explicit Scope(Type type);
+
// Scope tree.
Scope* outer_scope_; // the immediately enclosing outer scope, or NULL
ZoneList<Scope*> inner_scopes_; // the immediately enclosed inner scopes
@@ -375,7 +376,7 @@
class DummyScope : public Scope {
public:
- DummyScope() {
+ DummyScope() : Scope(GLOBAL_SCOPE) {
outer_scope_ = this;
}
« no previous file with comments | « no previous file | src/scopes.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698