Skip to content

OpenVINO™ is an open source toolkit for optimizing and deploying AI inference

Fix unused variable warning from OV_PASS_CALLBACK macro (#32628)

Arseniy Obolenskiy5c40eb695e72
diff --git a/src/common/conditional_compilation/include/openvino/cc/pass/itt.hpp b/src/common/conditional_compilation/include/openvino/cc/pass/itt.hpp
index 14b4b45c39b..634ee6e9951 100644
--- a/src/common/conditional_compilation/include/openvino/cc/pass/itt.hpp
+++ b/src/common/conditional_compilation/include/openvino/cc/pass/itt.hpp
@@ -26,7 +26,7 @@ OV_CC_DOMAINS(ov_pass);
# define REGISTER_DISABLED_PASS(obj, region, ...) obj.register_pass<region, false>(__VA_ARGS__);
# define OV_PASS_CALLBACK(matcher) \
- openvino::itt::handle_t m_callback_handle; \
+ [[maybe_unused]] openvino::itt::handle_t m_callback_handle; \
m_callback_handle = openvino::itt::handle(matcher->get_name()); \
OV_ITT_SCOPED_TASK(SIMPLE_ov_pass, m_callback_handle)
#elif defined(SELECTIVE_BUILD)