Add and fix warnings for unused functions and parameters
authorCharles Giessen <charles@lunarg.com>
Thu, 15 Jun 2023 21:47:23 +0000 (15:47 -0600)
committerCharles Giessen <46324611+charles-lunarg@users.noreply.github.com>
Fri, 16 Jun 2023 20:02:58 +0000 (14:02 -0600)
commitf004eeed0a1ec46a556b93bbed38582997ba8c0d
treef5a951dde98d57567b67150acad32d4ef6fbe231
parent5dba6d2a346e4134ecbf98d9691a185f20d131e1
Add and fix warnings for unused functions and parameters

These warnings were disabled, and this commit enables them.
It also fixes the many warnings that were present but were silenced. This
includes many unused parameters that could be safely removed. But it also
required marking some parameters as `(void)param;` to indicate to the
compiler that the parameter is infact required. If a function is a stub
function, then instead all of the names of the parameters were removed.

The biggest change is for vk_dispatch_table_helper.h which had stubs for
every device function. Rather than try to mark every parameter as unused
it was simpler to remove all stub functions, which aren't useful for
testing anyhow. Tests should crash rather than silently continue anyhow.
29 files changed:
CMakeLists.txt
loader/cJSON.c
loader/cJSON.h
loader/loader.c
loader/loader.h
loader/loader_environment.c
loader/loader_environment.h
loader/loader_windows.c
loader/log.c
loader/settings.c
loader/terminator.c
loader/vk_loader_platform.h
scripts/dispatch_table_helper_generator.py
tests/framework/icd/test_icd.cpp
tests/framework/json_writer.h
tests/framework/layer/test_layer.cpp
tests/framework/layer/vk_dispatch_table_helper.h
tests/framework/layer/wrap_objects.cpp
tests/framework/shim/shim_common.cpp
tests/framework/shim/windows_shim.cpp
tests/framework/test_environment.cpp
tests/framework/test_environment.h
tests/framework/test_util.h
tests/loader_alloc_callback_tests.cpp
tests/loader_debug_ext_tests.cpp
tests/loader_settings_tests.cpp
tests/loader_threading_tests.cpp
tests/loader_unknown_ext_tests.cpp
tests/loader_version_tests.cpp