github-actions[bot] commented on code in PR #18866: URL: https://github.com/apache/doris/pull/18866#discussion_r1173392347
########## be/src/service/point_query_executor.cpp: ########## @@ -41,11 +41,7 @@ namespace doris { -Reusable::~Reusable() { - for (vectorized::VExprContext* ctx : _output_exprs_ctxs) { - ctx->close(_runtime_state.get()); - } -} +Reusable::~Reusable() = default; Review Comment: warning: use '= default' to define a trivial destructor [modernize-use-equals-default] ```suggestion Reusable::~Reusable() = default; ``` ########## be/src/exec/base_scanner.h: ########## @@ -64,7 +64,7 @@ class BaseScanner { const std::vector<TNetworkAddress>& broker_addresses, const std::vector<TExpr>& pre_filter_texprs, ScannerCounter* counter); - virtual ~BaseScanner() { vectorized::VExpr::close(_dest_vexpr_ctx, _state); } + virtual ~BaseScanner() = default; Review Comment: warning: use '= default' to define a trivial destructor [modernize-use-equals-default] ```suggestion virtual ~BaseScanner() = default; ``` ########## be/src/vec/sink/vtablet_sink.cpp: ########## @@ -89,11 +89,7 @@ class TExpr; namespace stream_load { -IndexChannel::~IndexChannel() { - if (_where_clause != nullptr) { - _where_clause->close(_parent->_state); - } -} +IndexChannel::~IndexChannel() = default; Review Comment: warning: use '= default' to define a trivial destructor [modernize-use-equals-default] ```suggestion IndexChannel::~IndexChannel() = default; ``` ########## be/src/vec/exprs/vexpr_context.cpp: ########## @@ -42,14 +42,9 @@ VExprContext::VExprContext(VExpr* expr) _is_clone(false), _prepared(false), _opened(false), - _closed(false), _last_result_column_id(-1) {} -VExprContext::~VExprContext() { - // Do not delete this code, this code here is used to check if forget to close the opened context - // Or there will be memory leak - DCHECK(!_prepared || _closed) << get_stack_trace(); -} +VExprContext::~VExprContext() = default; Review Comment: warning: use '= default' to define a trivial destructor [modernize-use-equals-default] ```suggestion VExprContext::~VExprContext() = default; ``` -- 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: commits-unsubscr...@doris.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org