yixiutt commented on PR #16605:
URL: https://github.com/apache/doris/pull/16605#issuecomment-1427231123

   > Add a DCHECK for the type variable to make sure we used the right decoder?
   > 
   > ```
   > if constexpr (USED_IN_DICT_ENCODING) {
   >             auto type = decode_fixed32_le((const uint8_t*)&data.data[0]);
   >             if (static_cast<EncodingTypePB>(type) != 
EncodingTypePB::DICT_ENCODING) {
   >                 return Status::OK();
   >             }
   >             size_of_dict_header = BINARY_DICT_PAGE_HEADER_SIZE;
   >             data.remove_prefix(4);
   >         }
   > ```
   
   only USED_IN_DICT_ENCODING have a type, other encoder may encode offset or 
nums in the first bytes


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