yiguolei commented on code in PR #39030:
URL: https://github.com/apache/doris/pull/39030#discussion_r1709116066


##########
be/src/vec/common/assert_cast.h:
##########
@@ -26,11 +26,13 @@
 #include "common/logging.h"
 #include "vec/common/demangle.h"
 
+enum class TypeCheckOnRelease : bool { ENABLE = true, DISABLE = false };
+
 /** Perform static_cast in release build.
   * Checks type by comparing typeid and throw an exception in debug build.
   * The exact match of the type is checked. That is, cast to the ancestor will 
be unsuccessful.
   */
-template <typename To, typename From>
+template <typename To, TypeCheckOnRelease check = TypeCheckOnRelease::ENABLE, 
typename From>

Review Comment:
   Add  comment to explain why need this parameter



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