OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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/typing.h" | 5 #include "src/typing.h" |
6 | 6 |
7 #include "src/frames.h" | 7 #include "src/frames.h" |
8 #include "src/frames-inl.h" | 8 #include "src/frames-inl.h" |
9 #include "src/ostreams.h" | 9 #include "src/ostreams.h" |
10 #include "src/parser.h" // for CompileTimeValue; TODO(rossberg): should move | 10 #include "src/parser.h" // for CompileTimeValue; TODO(rossberg): should move |
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
129 | 129 |
130 void AstTyper::VisitExpressionStatement(ExpressionStatement* stmt) { | 130 void AstTyper::VisitExpressionStatement(ExpressionStatement* stmt) { |
131 RECURSE(Visit(stmt->expression())); | 131 RECURSE(Visit(stmt->expression())); |
132 } | 132 } |
133 | 133 |
134 | 134 |
135 void AstTyper::VisitEmptyStatement(EmptyStatement* stmt) { | 135 void AstTyper::VisitEmptyStatement(EmptyStatement* stmt) { |
136 } | 136 } |
137 | 137 |
138 | 138 |
| 139 void AstTyper::VisitSloppyBlockFunctionStatement( |
| 140 SloppyBlockFunctionStatement* stmt) { |
| 141 Visit(stmt->statement()); |
| 142 } |
| 143 |
| 144 |
139 void AstTyper::VisitIfStatement(IfStatement* stmt) { | 145 void AstTyper::VisitIfStatement(IfStatement* stmt) { |
140 // Collect type feedback. | 146 // Collect type feedback. |
141 if (!stmt->condition()->ToBooleanIsTrue() && | 147 if (!stmt->condition()->ToBooleanIsTrue() && |
142 !stmt->condition()->ToBooleanIsFalse()) { | 148 !stmt->condition()->ToBooleanIsFalse()) { |
143 stmt->condition()->RecordToBooleanTypeFeedback(oracle()); | 149 stmt->condition()->RecordToBooleanTypeFeedback(oracle()); |
144 } | 150 } |
145 | 151 |
146 RECURSE(Visit(stmt->condition())); | 152 RECURSE(Visit(stmt->condition())); |
147 Effects then_effects = EnterEffects(); | 153 Effects then_effects = EnterEffects(); |
148 RECURSE(Visit(stmt->then_statement())); | 154 RECURSE(Visit(stmt->then_statement())); |
(...skipping 651 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
800 void AstTyper::VisitImportDeclaration(ImportDeclaration* declaration) { | 806 void AstTyper::VisitImportDeclaration(ImportDeclaration* declaration) { |
801 } | 807 } |
802 | 808 |
803 | 809 |
804 void AstTyper::VisitExportDeclaration(ExportDeclaration* declaration) { | 810 void AstTyper::VisitExportDeclaration(ExportDeclaration* declaration) { |
805 } | 811 } |
806 | 812 |
807 | 813 |
808 } // namespace internal | 814 } // namespace internal |
809 } // namespace v8 | 815 } // namespace v8 |
OLD | NEW |