diff --git a/include/onnxruntime/core/graph/graph.h b/include/onnxruntime/core/graph/graph.h index b9b8a25286b7b..b7250d77f147b 100644 --- a/include/onnxruntime/core/graph/graph.h +++ b/include/onnxruntime/core/graph/graph.h @@ -21,8 +21,19 @@ #pragma warning(pop) #endif +#if defined(__GNUC__) +#pragma GCC diagnostic push + +#ifdef HAS_SHORTEN_64_TO_32 +#pragma GCC diagnostic ignored "-Wshorten-64-to-32" +#endif + #include "flatbuffers/flatbuffers.h" +#if defined(__GNUC__) +#pragma GCC diagnostic pop +#endif + #include "core/common/gsl.h" #include "core/common/common.h"