Skip to content

Commit 880bbc4

Browse files
committed
Rename too-verbose function name
sparse_tensor_format_id -> format_id
1 parent c83ea6a commit 880bbc4

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

cpp/src/arrow/compare.cc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -824,7 +824,7 @@ struct SparseTensorEqualsImpl<SparseIndexType, SparseIndexType> {
824824
template <typename SparseIndexType>
825825
inline bool SparseTensorEqualsImplDispatch(const SparseTensorImpl<SparseIndexType>& left,
826826
const SparseTensor& right) {
827-
switch (right.sparse_tensor_format_id()) {
827+
switch (right.format_id()) {
828828
case SparseTensorFormat::COO: {
829829
const auto& right_coo = checked_cast<const SparseTensorImpl<SparseCOOIndex>&>(right);
830830
return SparseTensorEqualsImpl<SparseIndexType, SparseCOOIndex>::Compare(left,
@@ -857,7 +857,7 @@ bool SparseTensorEquals(const SparseTensor& left, const SparseTensor& right) {
857857
return false;
858858
}
859859

860-
switch (left.sparse_tensor_format_id()) {
860+
switch (left.format_id()) {
861861
case SparseTensorFormat::COO: {
862862
const auto& left_coo = checked_cast<const SparseTensorImpl<SparseCOOIndex>&>(left);
863863
return SparseTensorEqualsImplDispatch(left_coo, right);

cpp/src/arrow/sparse_tensor-test.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ namespace arrow {
3434

3535
static inline void CheckSparseIndexFormatType(SparseTensorFormat::type expected,
3636
const SparseTensor& sparse_tensor) {
37-
ASSERT_EQ(expected, sparse_tensor.sparse_tensor_format_id());
37+
ASSERT_EQ(expected, sparse_tensor.format_id());
3838
ASSERT_EQ(expected, sparse_tensor.sparse_index()->format_id());
3939
}
4040

cpp/src/arrow/sparse_tensor.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ class ARROW_EXPORT SparseTensor {
117117
public:
118118
virtual ~SparseTensor() = default;
119119

120-
SparseTensorFormat::type sparse_tensor_format_id() const {
120+
SparseTensorFormat::type format_id() const {
121121
return sparse_index_->format_id();
122122
}
123123

0 commit comments

Comments
 (0)