Chromium Code Reviews| Index: runtime/vm/code_generator.cc |
| =================================================================== |
| --- runtime/vm/code_generator.cc (revision 6976) |
| +++ runtime/vm/code_generator.cc (working copy) |
| @@ -410,8 +410,18 @@ |
| AbstractTypeArguments::Handle(type.arguments()); |
| const bool is_raw_type = type_arguments.IsNull() || |
| type_arguments.IsRaw(type_arguments.Length()); |
| - if (!is_raw_type) { |
| - return; |
| + if (!is_raw_type && !type_arguments.IsNull()) { |
|
regis
2012/04/26 00:36:17
No need to check && !type_arguments.IsNull()
srdjan
2012/04/26 18:08:37
Done.
|
| + // We cannot inline tests for instances with more than one type argument |
| + // or if it's class has not been resolved (malformed type). |
|
regis
2012/04/26 00:36:17
its class
regis
2012/04/26 00:36:17
I do not think you can encounter a malformed type
srdjan
2012/04/26 18:08:37
I misunderstood your explanation of malformed type
|
| + if (type_arguments.Length() != 1) { |
| + // We can handle only one argument so far |
|
regis
2012/04/26 00:36:17
far.
srdjan
2012/04/26 18:08:37
Done.
|
| + return; |
| + } |
| + const AbstractType& type_argument_0 = |
|
regis
2012/04/26 00:36:17
type_argument instead of type_argument_0?
srdjan
2012/04/26 18:08:37
Removed that code.
|
| + AbstractType::ZoneHandle(type_arguments.TypeAt(0)); |
|
regis
2012/04/26 00:36:17
Why a ZoneHandle?
srdjan
2012/04/26 18:08:37
Handle
|
| + if (type_argument_0.IsType() && !type_argument_0.HasResolvedTypeClass()) { |
|
regis
2012/04/26 00:36:17
Are you checking for IsMalformed()?
But how can th
srdjan
2012/04/26 18:08:37
Converted to assert added comment why it can't be
|
| + return; |
| + } |
| } |
| } |
| StackFrameIterator iterator(StackFrameIterator::kDontValidateFrames); |