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

Unified Diff: src/ast/scopes.h

Issue 2318953003: Comment about why we don't record evals from inner scopes in the script scope (Closed)
Patch Set: updates Created 4 years, 3 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ast/scopes.h
diff --git a/src/ast/scopes.h b/src/ast/scopes.h
index d97f6209f164c2a74ac6db0e0ed820ac2e5aeda5..bc0334027242a8274198914a87d47eae0f774841 100644
--- a/src/ast/scopes.h
+++ b/src/ast/scopes.h
@@ -199,7 +199,10 @@ class Scope: public ZoneObject {
// Scope-specific info.
// Inform the scope and outer scopes that the corresponding code contains an
- // eval call.
+ // eval call. We don't record eval calls from innner scopes in the outer most
+ // script scope, as we only see those when parsing eagerly. If we recorded the
+ // calls then, the outer most script scope would look different depending on
+ // whether we parsed eagerly or not which is undesirable.
void RecordEvalCall() {
scope_calls_eval_ = true;
inner_scope_calls_eval_ = true;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698