From c3d2956ba588a4559fabc36a0c1fc7dd28279314 Mon Sep 17 00:00:00 2001 From: Tiger Wang Date: Thu, 17 Sep 2020 14:51:42 +0100 Subject: BlockHandler: no dynamic allocation (#4862) * BlockHandler: no dynamic allocation --- CMakeLists.txt | 3 +++ 1 file changed, 3 insertions(+) (limited to 'CMakeLists.txt') diff --git a/CMakeLists.txt b/CMakeLists.txt index 6fd2f2b22..7bd7c1941 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -92,6 +92,9 @@ if(CMAKE_CXX_COMPILER_ID STREQUAL "Clang") # File failed to follow NHS guidelines on handwashing and has not maintained good hygiene set_source_files_properties("${CMAKE_SOURCE_DIR}/src/IniFile.cpp" PROPERTIES COMPILE_OPTIONS -Wno-header-hygiene) + + # Enforce BlockHandler handling all blocks in switch statements + set_source_files_properties("${CMAKE_SOURCE_DIR}/src/Blocks/BlockHandler.cpp" PROPERTIES COMPILE_OPTIONS -Werror=switch) endif() if(${BUILD_TOOLS}) -- cgit v1.2.3