You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-04 12:00:25 +00:00
Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks
Which means that reduz' beloved style which we all became used to will now be changed automatically to remove the first empty line. This makes us lean closer to 1TBS (the one true brace style) instead of hybridating it with some Allman-inspired spacing. There's still the case of braces around single-statement blocks that needs to be addressed (but clang-format can't help with that, but clang-tidy may if we agree about it). Part of #33027.
This commit is contained in:
@@ -152,7 +152,6 @@ void XRServer::add_interface(const Ref<XRInterface> &p_interface) {
|
||||
ERR_FAIL_COND(p_interface.is_null());
|
||||
|
||||
for (int i = 0; i < interfaces.size(); i++) {
|
||||
|
||||
if (interfaces[i] == p_interface) {
|
||||
ERR_PRINT("Interface was already added");
|
||||
return;
|
||||
@@ -168,9 +167,7 @@ void XRServer::remove_interface(const Ref<XRInterface> &p_interface) {
|
||||
|
||||
int idx = -1;
|
||||
for (int i = 0; i < interfaces.size(); i++) {
|
||||
|
||||
if (interfaces[i] == p_interface) {
|
||||
|
||||
idx = i;
|
||||
break;
|
||||
};
|
||||
@@ -197,9 +194,7 @@ Ref<XRInterface> XRServer::get_interface(int p_index) const {
|
||||
Ref<XRInterface> XRServer::find_interface(const String &p_name) const {
|
||||
int idx = -1;
|
||||
for (int i = 0; i < interfaces.size(); i++) {
|
||||
|
||||
if (interfaces[i]->get_name() == p_name) {
|
||||
|
||||
idx = i;
|
||||
break;
|
||||
};
|
||||
@@ -277,9 +272,7 @@ void XRServer::remove_tracker(XRPositionalTracker *p_tracker) {
|
||||
|
||||
int idx = -1;
|
||||
for (int i = 0; i < trackers.size(); i++) {
|
||||
|
||||
if (trackers[i] == p_tracker) {
|
||||
|
||||
idx = i;
|
||||
break;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user