From 0ee0fa42e6639b6fa474b7cf6afc6b1a78142185 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Verschelde?= Date: Thu, 14 May 2020 16:41:43 +0200 Subject: Style: Enforce braces around if blocks and loops Using clang-tidy's `readability-braces-around-statements`. https://clang.llvm.org/extra/clang-tidy/checks/readability-braces-around-statements.html --- editor/plugins/visual_shader_editor_plugin.cpp | 92 +++++++++++++++++--------- 1 file changed, 61 insertions(+), 31 deletions(-) (limited to 'editor/plugins/visual_shader_editor_plugin.cpp') diff --git a/editor/plugins/visual_shader_editor_plugin.cpp b/editor/plugins/visual_shader_editor_plugin.cpp index 223cc249e1..92bdba93e7 100644 --- a/editor/plugins/visual_shader_editor_plugin.cpp +++ b/editor/plugins/visual_shader_editor_plugin.cpp @@ -103,8 +103,9 @@ void VisualShaderEditor::edit(VisualShader *p_visual_shader) { } void VisualShaderEditor::add_plugin(const Ref &p_plugin) { - if (plugins.find(p_plugin) != -1) + if (plugins.find(p_plugin) != -1) { return; + } plugins.push_back(p_plugin); } @@ -127,8 +128,9 @@ void VisualShaderEditor::add_custom_type(const String &p_name, const Ref