diff options
| author | Rémi Verschelde <rverschelde@gmail.com> | 2020-05-10 12:56:01 +0200 |
|---|---|---|
| committer | Rémi Verschelde <rverschelde@gmail.com> | 2020-05-10 13:12:16 +0200 |
| commit | e956e80c1fa1cc8aefcb1533e5acf5cf3c8ffdd9 (patch) | |
| tree | 8f162f9162ca0dfa35841a9c734a0529764cb458 /editor/code_editor.cpp | |
| parent | 03b13e0c695bb63043c3ca8665083bae1960aca4 (diff) | |
| download | redot-engine-e956e80c1fa1cc8aefcb1533e5acf5cf3c8ffdd9.tar.gz | |
Style: clang-format: Disable AllowShortIfStatementsOnASingleLine
Part of #33027, also discussed in #29848.
Enforcing the use of brackets even on single line statements would be
preferred, but `clang-format` doesn't have this functionality yet.
Diffstat (limited to 'editor/code_editor.cpp')
| -rw-r--r-- | editor/code_editor.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/editor/code_editor.cpp b/editor/code_editor.cpp index 987d5649b1..76716f01b7 100644 --- a/editor/code_editor.cpp +++ b/editor/code_editor.cpp @@ -309,7 +309,8 @@ void FindReplaceBar::_update_results_count() { results_count = 0; String searched = get_search_text(); - if (searched.empty()) return; + if (searched.empty()) + return; String full_text = text_edit->get_text(); @@ -317,7 +318,8 @@ void FindReplaceBar::_update_results_count() { while (true) { int pos = is_case_sensitive() ? full_text.find(searched, from_pos) : full_text.findn(searched, from_pos); - if (pos == -1) break; + if (pos == -1) + break; if (is_whole_words()) { from_pos++; // Making sure we won't hit the same match next time, if we get out via a continue. |
