This is an automated email from the ASF dual-hosted git repository.
gangwu pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/arrow.git
The following commit(s) were added to refs/heads/main by this push:
new 0d4f043d45 GH-49408: [C++][Parquet] Add public virtual destructor to
`parquet::Page` (#49409)
0d4f043d45 is described below
commit 0d4f043d453979a71582e8ffb8d9cf5e54d2b7d0
Author: Zehua Zou <[email protected]>
AuthorDate: Mon Mar 9 10:41:51 2026 +0800
GH-49408: [C++][Parquet] Add public virtual destructor to `parquet::Page`
(#49409)
### Rationale for this change
Clarify the destructor implementation of `parquet::Page` to expose the
design intent.
### What changes are included in this PR?
Add public virtual destructor to `parquet::Page`.
### Are these changes tested?
Yes.
### Are there any user-facing changes?
No.
* GitHub Issue: #49408
Authored-by: Zehua Zou <[email protected]>
Signed-off-by: Gang Wu <[email protected]>
---
cpp/src/parquet/column_page.h | 2 ++
1 file changed, 2 insertions(+)
diff --git a/cpp/src/parquet/column_page.h b/cpp/src/parquet/column_page.h
index 111265a842..1b3d4cfd41 100644
--- a/cpp/src/parquet/column_page.h
+++ b/cpp/src/parquet/column_page.h
@@ -44,6 +44,8 @@ class Page {
Page(const std::shared_ptr<Buffer>& buffer, PageType::type type)
: buffer_(buffer), type_(type) {}
+ virtual ~Page() = default;
+
PageType::type type() const { return type_; }
std::shared_ptr<Buffer> buffer() const { return buffer_; }