Remove implicit fallthroughs; Add warning
authorCharles Giessen <charles@lunarg.com>
Tue, 1 Nov 2022 04:37:31 +0000 (22:37 -0600)
committerCharles Giessen <46324611+charles-lunarg@users.noreply.github.com>
Tue, 1 Nov 2022 21:05:40 +0000 (15:05 -0600)
commit3f29209dd65d52dfd5e07dd77621a718c7a4042c
treefb336067fec8a912a2f66d7d075777c6544c05ac
parenta17d7fc737e650070e50655b877be1aa206a2031
Remove implicit fallthroughs; Add warning

Previously, cJSON used implicit fallthrough in a switch statement. Naked
fallthroughs are a common bug source, and while this use case was well
behaved, it did require disabling the compiler warnings for it. Thus,
converting it to an explicit for loop prevents unnecessary compiler
warning flags being disabled.
BUILD.gn
CMakeLists.txt
build-qnx/common.mk
loader/cJSON.c