From 29567e1674b09e6eae7ff02a071236ae784486ea Mon Sep 17 00:00:00 2001 From: Carter Li Date: Sun, 11 Oct 2026 23:49:07 +0800 Subject: [PATCH] Chore: eliminates compiler warnings --- src/common/lua.h | 1 + src/common/zlib.h | 5 ++--- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/common/lua.h b/src/common/lua.h index fab613f12..b012dfc9e 100644 --- a/src/common/lua.h +++ b/src/common/lua.h @@ -13,6 +13,7 @@ #define LUALIB_API LUA_API #define LUAMOD_API LUA_API + // Note: `#pragma GCC diagnostic push` is intentionally omitted here. #pragma GCC diagnostic ignored "-Wunused-function" #endif diff --git a/src/common/zlib.h b/src/common/zlib.h index 4ea434437..02a2f79a6 100644 --- a/src/common/zlib.h +++ b/src/common/zlib.h @@ -44,13 +44,12 @@ static inline const char* ffZlibLoad([[maybe_unused]] FFZlibGroup group) { // that a given translation unit may not call at all. Silenced for the include only: the // pragma is popped right after, so the rest of the file -- and the rest of the translation // unit that includes this header -- still reports unused functions. - #pragma GCC diagnostic push + + // Note: `#pragma GCC diagnostic push` is intentionally omitted here. #pragma GCC diagnostic ignored "-Wunused-function" #include - #pragma GCC diagnostic pop - #include "common/library.h" extern struct FFZlibData {