github-actions[bot] commented on code in PR #19155: URL: https://github.com/apache/doris/pull/19155#discussion_r1178745986
########## be/src/common/factory_creator.h: ########## @@ -35,21 +35,33 @@ // during inherits // TODO try to allow make_unique // -#define ENABLE_FACTORY_CREATOR(TypeName) \ -private: \ - void* operator new(std::size_t size) { return ::operator new(size); } \ - void* operator new[](std::size_t size) { return ::operator new[](size); } \ - \ -public: \ - void* operator new(std::size_t count, void* ptr) { return ::operator new(count, ptr); } \ - void operator delete(void* ptr) noexcept { ::operator delete(ptr); } \ - void operator delete[](void* ptr) noexcept { ::operator delete[](ptr); } \ - void operator delete(void* ptr, void* place) noexcept { ::operator delete(ptr, place); } \ - template <typename... Args> \ - static std::shared_ptr<TypeName> create_shared(Args&&... args) { \ - return std::make_shared<TypeName>(std::forward<Args>(args)...); \ - } \ - template <typename... Args> \ - static std::unique_ptr<TypeName> create_unique(Args&&... args) { \ - return std::unique_ptr<TypeName>(new TypeName(std::forward<Args>(args)...)); \ +#define ENABLE_FACTORY_CREATOR(TypeName) \ Review Comment: warning: macro is not used [clang-diagnostic-unused-macros] ```cpp #define ENABLE_FACTORY_CREATOR(TypeName) \ ^ ``` -- 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