From 2cf6ac6c507529884d6b8acfdc42f3bc1826b19d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Verschelde?= Date: Sat, 22 Feb 2020 20:47:50 +0100 Subject: Replace FALLTHROUGH macro by C++17 [[fallthrough]] This attribute is now part of the standard we target so we no longer need compiler-specific hacks. Also enables -Wimplicit-fallthrough for Clang now that we can properly support it. It's already on by default for GCC's -Wextra. Fixes new warnings raised by Clang's -Wimplicit-fallthrough. --- editor/editor_node.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'editor/editor_node.cpp') diff --git a/editor/editor_node.cpp b/editor/editor_node.cpp index 413959bb99..d8043f016b 100644 --- a/editor/editor_node.cpp +++ b/editor/editor_node.cpp @@ -2178,7 +2178,7 @@ void EditorNode::_menu_option_confirm(int p_option, bool p_confirmed) { break; } - FALLTHROUGH; + [[fallthrough]]; } case SCENE_TAB_CLOSE: case FILE_SAVE_SCENE: { @@ -2199,7 +2199,7 @@ void EditorNode::_menu_option_confirm(int p_option, bool p_confirmed) { break; } - FALLTHROUGH; + [[fallthrough]]; } case FILE_SAVE_AS_SCENE: { int scene_idx = (p_option == FILE_SAVE_SCENE || p_option == FILE_SAVE_AS_SCENE) ? -1 : tab_closing; -- cgit v1.2.3