meson: add -Wgnu-pointer-arith to _trial_msvc
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run

In theory, this will prevent the warning in the future
in common code (which uses c_msvc_compat_args).

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38752>
This commit is contained in:
Gurchetan Singh 2025-12-01 16:07:27 -08:00 committed by Marge Bot
parent 14cfe14626
commit 6c1d993640

View file

@ -1255,7 +1255,12 @@ else
# Check for C and C++ arguments for MSVC compatibility. These are only used
# in parts of the mesa code base that need to compile with MSVC, mainly
# common code
_trial_msvc = ['-Werror=pointer-arith', '-Werror=vla', '-Werror=gnu-empty-initializer']
_trial_msvc = [
'-Werror=pointer-arith',
'-Werror=vla',
'-Werror=gnu-empty-initializer',
'-Wgnu-pointer-arith',
]
c_msvc_compat_args += cc.get_supported_arguments(_trial_msvc)
cpp_msvc_compat_args += cpp.get_supported_arguments(_trial_msvc)
endif