OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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/typer.h" | 5 #include "src/compiler/typer.h" |
6 | 6 |
7 #include "src/base/flags.h" | 7 #include "src/base/flags.h" |
8 #include "src/bootstrapper.h" | 8 #include "src/bootstrapper.h" |
9 #include "src/compilation-dependencies.h" | 9 #include "src/compilation-dependencies.h" |
10 #include "src/compiler/common-operator.h" | 10 #include "src/compiler/common-operator.h" |
(...skipping 1215 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1226 return Type::OtherObject(); | 1226 return Type::OtherObject(); |
1227 } | 1227 } |
1228 | 1228 |
1229 | 1229 |
1230 Type* Typer::Visitor::TypeJSCreateClosure(Node* node) { | 1230 Type* Typer::Visitor::TypeJSCreateClosure(Node* node) { |
1231 return Type::OtherObject(); | 1231 return Type::OtherObject(); |
1232 } | 1232 } |
1233 | 1233 |
1234 | 1234 |
1235 Type* Typer::Visitor::TypeJSCreateLiteralArray(Node* node) { | 1235 Type* Typer::Visitor::TypeJSCreateLiteralArray(Node* node) { |
1236 return Type::None(), Type::OtherObject(); | 1236 return Type::OtherObject(); |
1237 } | 1237 } |
1238 | 1238 |
1239 | 1239 |
1240 Type* Typer::Visitor::TypeJSCreateLiteralObject(Node* node) { | 1240 Type* Typer::Visitor::TypeJSCreateLiteralObject(Node* node) { |
1241 return Type::OtherObject(); | 1241 return Type::OtherObject(); |
1242 } | 1242 } |
1243 | 1243 |
| 1244 |
| 1245 Type* Typer::Visitor::TypeJSCreateLiteralRegExp(Node* node) { |
| 1246 return Type::OtherObject(); |
| 1247 } |
| 1248 |
1244 | 1249 |
1245 Type* Typer::Visitor::JSLoadPropertyTyper(Type* object, Type* name, Typer* t) { | 1250 Type* Typer::Visitor::JSLoadPropertyTyper(Type* object, Type* name, Typer* t) { |
1246 // TODO(rossberg): Use range types and sized array types to filter undefined. | 1251 // TODO(rossberg): Use range types and sized array types to filter undefined. |
1247 if (object->IsArray() && name->Is(Type::Integral32())) { | 1252 if (object->IsArray() && name->Is(Type::Integral32())) { |
1248 return Type::Union( | 1253 return Type::Union( |
1249 object->AsArray()->Element(), Type::Undefined(), t->zone()); | 1254 object->AsArray()->Element(), Type::Undefined(), t->zone()); |
1250 } | 1255 } |
1251 return Type::Any(); | 1256 return Type::Any(); |
1252 } | 1257 } |
1253 | 1258 |
(...skipping 1107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2361 } | 2366 } |
2362 if (Type::IsInteger(*value)) { | 2367 if (Type::IsInteger(*value)) { |
2363 return Type::Range(value->Number(), value->Number(), zone()); | 2368 return Type::Range(value->Number(), value->Number(), zone()); |
2364 } | 2369 } |
2365 return Type::Constant(value, zone()); | 2370 return Type::Constant(value, zone()); |
2366 } | 2371 } |
2367 | 2372 |
2368 } // namespace compiler | 2373 } // namespace compiler |
2369 } // namespace internal | 2374 } // namespace internal |
2370 } // namespace v8 | 2375 } // namespace v8 |
OLD | NEW |