fix casting of lists
- remove type check - the casting for atomics takes care of that
diff --git a/asterix-om/src/main/java/edu/uci/ics/asterix/om/pointables/cast/AListCaster.java b/asterix-om/src/main/java/edu/uci/ics/asterix/om/pointables/cast/AListCaster.java
index d46c800..77ae09a 100644
--- a/asterix-om/src/main/java/edu/uci/ics/asterix/om/pointables/cast/AListCaster.java
+++ b/asterix-om/src/main/java/edu/uci/ics/asterix/om/pointables/cast/AListCaster.java
@@ -83,13 +83,10 @@
.getStartOffset()]);
if (reqItemType == null || reqItemType.getTypeTag().equals(ATypeTag.ANY)) {
itemVisitorArg.second = DefaultOpenFieldType.getDefaultOpenFieldType(typeTag);
- item.accept(visitor, itemVisitorArg);
} else {
- if (typeTag != reqItemType.getTypeTag())
- throw new AsterixException("mismatched item type");
itemVisitorArg.second = reqItemType;
- item.accept(visitor, itemVisitorArg);
}
+ item.accept(visitor, itemVisitorArg);
if (reqType.getTypeTag().equals(ATypeTag.ORDEREDLIST)) {
orderedListBuilder.addItem(itemVisitorArg.first);
}