File tree 1 file changed +8
-5
lines changed 1 file changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -17543,16 +17543,19 @@ RawAbstractType* Type::Canonicalize(TrailPtr trail) const {
17543
17543
Zone* zone = thread->zone();
17544
17544
Isolate* isolate = thread->isolate();
17545
17545
17546
- // Since void is a keyword, we never have to canonicalize the void type after
17547
- // it is canonicalized once by the vm isolate. The parser does the mapping.
17548
- ASSERT((type_class_id() != kVoidCid) || (isolate == Dart::vm_isolate()));
17546
+ if ((type_class_id() == kVoidCid) && (isolate != Dart::vm_isolate())) {
17547
+ ASSERT(Object::void_type().IsCanonical());
17548
+ return Object::void_type().raw();
17549
+ }
17549
17550
17550
- // Since dynamic is not a keyword, the parser builds a type that requires
17551
- // canonicalization.
17552
17551
if ((type_class_id() == kDynamicCid) && (isolate != Dart::vm_isolate())) {
17553
17552
ASSERT(Object::dynamic_type().IsCanonical());
17554
17553
return Object::dynamic_type().raw();
17555
17554
}
17555
+ if ((type_class_id() == kVectorCid) && (isolate != Dart::vm_isolate())) {
17556
+ ASSERT(Object::vector_type().IsCanonical());
17557
+ return Object::vector_type().raw();
17558
+ }
17556
17559
17557
17560
const Class& cls = Class::Handle(zone, type_class());
17558
17561
You can’t perform that action at this time.
0 commit comments