zzzxl1993 commented on code in PR #245:
URL: https://github.com/apache/doris-thirdparty/pull/245#discussion_r1827554420


##########
src/core/CLucene/index/FieldConfig.h:
##########
@@ -0,0 +1,11 @@
+#pragma once
+
+#include <cstdint>
+
+enum class FlagBits : uint32_t {
+    DICT_COMPRESS = 1 << 0, // 00000000 00000000 00000000 00000001
+};
+
+static bool isFlagSet(uint32_t flags, FlagBits flag) {
+    return flags & static_cast<uint32_t>(flag);

Review Comment:
   Even though flags is already of type uint32_t, using 
static_cast<uint32_t>(flag) ensures that flag (which is of type FlagBits) is 
explicitly converted to uint32_t. This improves type safety and clarity, 
avoiding any potential implicit conversions that could lead to unexpected 
behavior.



-- 
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: dev-unsubscr...@doris.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@doris.apache.org
For additional commands, e-mail: dev-h...@doris.apache.org

Reply via email to