diff --git a/cpp/src/arrow/array/array_dict_test.cc b/cpp/src/arrow/array/array_dict_test.cc index 1ee4dad922d99..78c18aefc78e8 100644 --- a/cpp/src/arrow/array/array_dict_test.cc +++ b/cpp/src/arrow/array/array_dict_test.cc @@ -1433,7 +1433,7 @@ void CheckDictionaryCountNullValues(const std::shared_ptr& dict_type, const std::string& input_index_json, const int64_t& expected_null_count) { auto input = DictArrayFromJSON(dict_type, input_index_json, input_dictionary_json); - const DictionaryArray& input_ref = checked_cast(*input); + const auto& input_ref = checked_cast(*input); ASSERT_OK_AND_ASSIGN(int64_t actual, input_ref.CountNullValues()); ASSERT_EQ(expected_null_count, actual);