CaptainAni187 opened a new pull request, #51811: URL: https://github.com/apache/arrow/pull/51811
### Rationale for this change In `GetSchema`, the loop over the schema's fields checked each `Field` for null with the label `"DictionaryEncoding.indexType"`. That label belongs to a different check, so if this one ever failed, the error would point at the wrong field. As the `XXX` comment next to it said, the check also can't fail: for a vector of tables, `fields()->Get(i)` returns the element's address plus its stored offset, never null. `Schema.fields` itself is already checked for null just above. ### What changes are included in this PR? The check and its comment are removed, which is the first option in the issue. Child fields in `FieldFromFlatbuffer` are already read through `children->Get(i)` without a null check, so top-level fields now match. ### Are these changes tested? No new test, since the removed check couldn't fail. The `arrow-ipc-*` tests pass locally. ### Are there any user-facing changes? No. ### Was AI used for this PR? In accordance to the [AI generation guidelines](https://arrow.apache.org/docs/dev/developers/overview.html#ai-generated-code), please disclose below whether and how AI was used in this PR. **PR code and description written by:** - [ ] Human - [ ] AI **Reviewed before submission by:** - [ ] Human - [ ] AI - [ ] Not reviewed -- 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]
