xinyiZzz commented on code in PR #19472:
URL: https://github.com/apache/doris/pull/19472#discussion_r1193187869


##########
be/src/olap/rowset/segment_v2/page_handle.h:
##########
@@ -46,42 +46,49 @@ class PageHandle {
             : _is_data_owner(false), _cache_data(std::move(cache_data)) {}
 
     // Move constructor
-    PageHandle(PageHandle&& other) noexcept
-            : _is_data_owner(false),
-              _data(std::move(other._data)),
-              _cache_data(std::move(other._cache_data)) {
+    PageHandle(PageHandle&& other) noexcept : 
_cache_data(std::move(other._cache_data)) {
         // we can use std::exchange if we switch c++14 on

Review Comment:
   `_is_data_owner` is initialized to false at definition time before the body 
of the copy constructor is executed
   
   swap has no special meaning, it has the same meaning as a = b, b = false



-- 
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

Reply via email to