pitrou commented on code in PR #33634:
URL: https://github.com/apache/arrow/pull/33634#discussion_r1072056477
##########
cpp/src/parquet/arrow/reader.cc:
##########
@@ -842,7 +842,16 @@ Status GetReader(const SchemaField& field, const
std::shared_ptr<Field>& arrow_f
auto storage_field = arrow_field->WithType(
checked_cast<const
ExtensionType&>(*arrow_field->type()).storage_type());
RETURN_NOT_OK(GetReader(field, storage_field, ctx, out));
- *out = std::make_unique<ExtensionReader>(arrow_field, std::move(*out));
+ if (*out) {
+ auto storage_type = (*out)->field()->type();
+ if (!storage_type->Equals(
+ checked_cast<const
ExtensionType&>(*arrow_field->type()).storage_type())) {
Review Comment:
Isn't this simply
```suggestion
if (!storage_type->Equals(storage_field->type()) {
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]