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

Side by Side Diff: src/compiler.cc

Issue 2218083002: Remove bool result from analyze since it's always true (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebase Created 4 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 unified diff | Download patch
« no previous file with comments | « src/ast/scopes.cc ('k') | test/cctest/compiler/test-loop-assignment-analysis.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/compiler.h" 5 #include "src/compiler.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <memory> 8 #include <memory>
9 9
10 #include "src/asmjs/asm-js.h" 10 #include "src/asmjs/asm-js.h"
(...skipping 1175 matching lines...) Expand 10 before | Expand all | Expand 10 after
1186 } 1186 }
1187 1187
1188 } // namespace 1188 } // namespace
1189 1189
1190 // ---------------------------------------------------------------------------- 1190 // ----------------------------------------------------------------------------
1191 // Implementation of Compiler 1191 // Implementation of Compiler
1192 1192
1193 bool Compiler::Analyze(ParseInfo* info) { 1193 bool Compiler::Analyze(ParseInfo* info) {
1194 DCHECK_NOT_NULL(info->literal()); 1194 DCHECK_NOT_NULL(info->literal());
1195 if (!Rewriter::Rewrite(info)) return false; 1195 if (!Rewriter::Rewrite(info)) return false;
1196 if (!Scope::Analyze(info)) return false; 1196 Scope::Analyze(info);
1197 if (!Renumber(info)) return false; 1197 if (!Renumber(info)) return false;
1198 DCHECK_NOT_NULL(info->scope()); 1198 DCHECK_NOT_NULL(info->scope());
1199 return true; 1199 return true;
1200 } 1200 }
1201 1201
1202 bool Compiler::ParseAndAnalyze(ParseInfo* info) { 1202 bool Compiler::ParseAndAnalyze(ParseInfo* info) {
1203 if (!Parser::ParseStatic(info)) return false; 1203 if (!Parser::ParseStatic(info)) return false;
1204 if (!Compiler::Analyze(info)) return false; 1204 if (!Compiler::Analyze(info)) return false;
1205 DCHECK_NOT_NULL(info->literal()); 1205 DCHECK_NOT_NULL(info->literal());
1206 DCHECK_NOT_NULL(info->scope()); 1206 DCHECK_NOT_NULL(info->scope());
(...skipping 737 matching lines...) Expand 10 before | Expand all | Expand 10 after
1944 DCHECK(shared->is_compiled()); 1944 DCHECK(shared->is_compiled());
1945 function->set_literals(cached.literals); 1945 function->set_literals(cached.literals);
1946 } else if (shared->is_compiled()) { 1946 } else if (shared->is_compiled()) {
1947 // TODO(mvstanton): pass pretenure flag to EnsureLiterals. 1947 // TODO(mvstanton): pass pretenure flag to EnsureLiterals.
1948 JSFunction::EnsureLiterals(function); 1948 JSFunction::EnsureLiterals(function);
1949 } 1949 }
1950 } 1950 }
1951 1951
1952 } // namespace internal 1952 } // namespace internal
1953 } // namespace v8 1953 } // namespace v8
OLDNEW
« no previous file with comments | « src/ast/scopes.cc ('k') | test/cctest/compiler/test-loop-assignment-analysis.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698