summaryrefslogtreecommitdiff
path: root/modules/gdscript
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2022-07-23 23:41:51 +0200
committerRémi Verschelde <rverschelde@gmail.com>2022-07-25 11:17:40 +0200
commit90019676b076abdfc076ed6f38005d6cce89923b (patch)
tree63fcbfc3018ae9953b1ef8049c51a07cd1a8728e /modules/gdscript
parent3084a48ace3e7dabd83e4c62280328f429defad6 (diff)
Code quality: Fix header guards consistency
Adds `header_guards.sh` bash script, used in CI to validate future changes. Can be run locally to fix invalid header guards.
Diffstat (limited to 'modules/gdscript')
-rw-r--r--modules/gdscript/gdscript_byte_codegen.h6
-rw-r--r--modules/gdscript/gdscript_codegen.h6
-rw-r--r--modules/gdscript/gdscript_lambda_callable.h6
-rw-r--r--modules/gdscript/gdscript_rpc_callable.h6
-rw-r--r--modules/gdscript/gdscript_tokenizer.h2
-rw-r--r--modules/gdscript/gdscript_warning.h6
-rw-r--r--modules/gdscript/language_server/gdscript_extend_parser.h4
-rw-r--r--modules/gdscript/language_server/gdscript_language_protocol.h2
-rw-r--r--modules/gdscript/language_server/gdscript_text_document.h4
-rw-r--r--modules/gdscript/language_server/gdscript_workspace.h4
-rw-r--r--modules/gdscript/language_server/godot_lsp.h (renamed from modules/gdscript/language_server/lsp.hpp)4
-rw-r--r--modules/gdscript/tests/gdscript_test_runner.h6
12 files changed, 28 insertions, 28 deletions
diff --git a/modules/gdscript/gdscript_byte_codegen.h b/modules/gdscript/gdscript_byte_codegen.h
index f4b402fc96..ffc3178c83 100644
--- a/modules/gdscript/gdscript_byte_codegen.h
+++ b/modules/gdscript/gdscript_byte_codegen.h
@@ -28,8 +28,8 @@
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
/*************************************************************************/
-#ifndef GDSCRIPT_BYTE_CODEGEN
-#define GDSCRIPT_BYTE_CODEGEN
+#ifndef GDSCRIPT_BYTE_CODEGEN_H
+#define GDSCRIPT_BYTE_CODEGEN_H
#include "gdscript_codegen.h"
@@ -502,4 +502,4 @@ public:
virtual ~GDScriptByteCodeGenerator();
};
-#endif // GDSCRIPT_BYTE_CODEGEN
+#endif // GDSCRIPT_BYTE_CODEGEN_H
diff --git a/modules/gdscript/gdscript_codegen.h b/modules/gdscript/gdscript_codegen.h
index 81fa265aca..7b5f133ec5 100644
--- a/modules/gdscript/gdscript_codegen.h
+++ b/modules/gdscript/gdscript_codegen.h
@@ -28,8 +28,8 @@
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
/*************************************************************************/
-#ifndef GDSCRIPT_CODEGEN
-#define GDSCRIPT_CODEGEN
+#ifndef GDSCRIPT_CODEGEN_H
+#define GDSCRIPT_CODEGEN_H
#include "core/multiplayer/multiplayer.h"
#include "core/string/string_name.h"
@@ -163,4 +163,4 @@ public:
virtual ~GDScriptCodeGenerator() {}
};
-#endif // GDSCRIPT_CODEGEN
+#endif // GDSCRIPT_CODEGEN_H
diff --git a/modules/gdscript/gdscript_lambda_callable.h b/modules/gdscript/gdscript_lambda_callable.h
index 248176e32c..1954089983 100644
--- a/modules/gdscript/gdscript_lambda_callable.h
+++ b/modules/gdscript/gdscript_lambda_callable.h
@@ -28,8 +28,8 @@
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
/*************************************************************************/
-#ifndef GDSCRIPT_LAMBDA_CALLABLE
-#define GDSCRIPT_LAMBDA_CALLABLE
+#ifndef GDSCRIPT_LAMBDA_CALLABLE_H
+#define GDSCRIPT_LAMBDA_CALLABLE_H
#include "core/object/ref_counted.h"
#include "core/templates/vector.h"
@@ -87,4 +87,4 @@ public:
virtual ~GDScriptLambdaSelfCallable() = default;
};
-#endif // GDSCRIPT_LAMBDA_CALLABLE
+#endif // GDSCRIPT_LAMBDA_CALLABLE_H
diff --git a/modules/gdscript/gdscript_rpc_callable.h b/modules/gdscript/gdscript_rpc_callable.h
index 2c8734a74b..c8a91d6259 100644
--- a/modules/gdscript/gdscript_rpc_callable.h
+++ b/modules/gdscript/gdscript_rpc_callable.h
@@ -28,8 +28,8 @@
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
/*************************************************************************/
-#ifndef GDSCRIPT_RPC_CALLABLE
-#define GDSCRIPT_RPC_CALLABLE
+#ifndef GDSCRIPT_RPC_CALLABLE_H
+#define GDSCRIPT_RPC_CALLABLE_H
#include "core/variant/callable.h"
#include "core/variant/variant.h"
@@ -58,4 +58,4 @@ public:
virtual ~GDScriptRPCCallable() = default;
};
-#endif // GDSCRIPT_RPC_CALLABLE
+#endif // GDSCRIPT_RPC_CALLABLE_H
diff --git a/modules/gdscript/gdscript_tokenizer.h b/modules/gdscript/gdscript_tokenizer.h
index 7fb715f2c8..68b2c6eb1c 100644
--- a/modules/gdscript/gdscript_tokenizer.h
+++ b/modules/gdscript/gdscript_tokenizer.h
@@ -273,4 +273,4 @@ public:
GDScriptTokenizer();
};
-#endif
+#endif // GDSCRIPT_TOKENIZER_H
diff --git a/modules/gdscript/gdscript_warning.h b/modules/gdscript/gdscript_warning.h
index f47f31aedf..a639e7b44e 100644
--- a/modules/gdscript/gdscript_warning.h
+++ b/modules/gdscript/gdscript_warning.h
@@ -28,8 +28,8 @@
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
/*************************************************************************/
-#ifndef GDSCRIPT_WARNINGS
-#define GDSCRIPT_WARNINGS
+#ifndef GDSCRIPT_WARNING_H
+#define GDSCRIPT_WARNING_H
#ifdef DEBUG_ENABLED
@@ -97,4 +97,4 @@ public:
#endif // DEBUG_ENABLED
-#endif // GDSCRIPT_WARNINGS
+#endif // GDSCRIPT_WARNING_H
diff --git a/modules/gdscript/language_server/gdscript_extend_parser.h b/modules/gdscript/language_server/gdscript_extend_parser.h
index 99b0bf45d0..08bba4a2d4 100644
--- a/modules/gdscript/language_server/gdscript_extend_parser.h
+++ b/modules/gdscript/language_server/gdscript_extend_parser.h
@@ -33,7 +33,7 @@
#include "../gdscript_parser.h"
#include "core/variant/variant.h"
-#include "lsp.hpp"
+#include "godot_lsp.h"
#ifndef LINE_NUMBER_TO_INDEX
#define LINE_NUMBER_TO_INDEX(p_line) ((p_line)-1)
@@ -99,4 +99,4 @@ public:
Error parse(const String &p_code, const String &p_path);
};
-#endif
+#endif // GDSCRIPT_EXTEND_PARSER_H
diff --git a/modules/gdscript/language_server/gdscript_language_protocol.h b/modules/gdscript/language_server/gdscript_language_protocol.h
index 0fed8597f9..3c9cfe512f 100644
--- a/modules/gdscript/language_server/gdscript_language_protocol.h
+++ b/modules/gdscript/language_server/gdscript_language_protocol.h
@@ -36,7 +36,7 @@
#include "core/io/tcp_server.h"
#include "gdscript_text_document.h"
#include "gdscript_workspace.h"
-#include "lsp.hpp"
+#include "godot_lsp.h"
#include "modules/modules_enabled.gen.h" // For jsonrpc.
#ifdef MODULE_JSONRPC_ENABLED
diff --git a/modules/gdscript/language_server/gdscript_text_document.h b/modules/gdscript/language_server/gdscript_text_document.h
index 9732765f34..87bc08a34e 100644
--- a/modules/gdscript/language_server/gdscript_text_document.h
+++ b/modules/gdscript/language_server/gdscript_text_document.h
@@ -33,7 +33,7 @@
#include "core/io/file_access.h"
#include "core/object/ref_counted.h"
-#include "lsp.hpp"
+#include "godot_lsp.h"
class GDScriptTextDocument : public RefCounted {
GDCLASS(GDScriptTextDocument, RefCounted)
@@ -77,4 +77,4 @@ public:
GDScriptTextDocument();
};
-#endif
+#endif // GDSCRIPT_TEXT_DOCUMENT_H
diff --git a/modules/gdscript/language_server/gdscript_workspace.h b/modules/gdscript/language_server/gdscript_workspace.h
index 7bff5db81f..88f3aaf957 100644
--- a/modules/gdscript/language_server/gdscript_workspace.h
+++ b/modules/gdscript/language_server/gdscript_workspace.h
@@ -35,7 +35,7 @@
#include "core/variant/variant.h"
#include "editor/editor_file_system.h"
#include "gdscript_extend_parser.h"
-#include "lsp.hpp"
+#include "godot_lsp.h"
class GDScriptWorkspace : public RefCounted {
GDCLASS(GDScriptWorkspace, RefCounted);
@@ -100,4 +100,4 @@ public:
~GDScriptWorkspace();
};
-#endif
+#endif // GDSCRIPT_WORKSPACE_H
diff --git a/modules/gdscript/language_server/lsp.hpp b/modules/gdscript/language_server/godot_lsp.h
index 1c9349097f..fbd40796c4 100644
--- a/modules/gdscript/language_server/lsp.hpp
+++ b/modules/gdscript/language_server/godot_lsp.h
@@ -1,5 +1,5 @@
/*************************************************************************/
-/* lsp.hpp */
+/* godot_lsp.h */
/*************************************************************************/
/* This file is part of: */
/* GODOT ENGINE */
@@ -1975,4 +1975,4 @@ static String marked_documentation(const String &p_bbcode) {
}
} // namespace lsp
-#endif
+#endif // GODOT_LSP_H
diff --git a/modules/gdscript/tests/gdscript_test_runner.h b/modules/gdscript/tests/gdscript_test_runner.h
index ee21afd9c9..033d2fcad1 100644
--- a/modules/gdscript/tests/gdscript_test_runner.h
+++ b/modules/gdscript/tests/gdscript_test_runner.h
@@ -28,8 +28,8 @@
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
/*************************************************************************/
-#ifndef GDSCRIPT_TEST_H
-#define GDSCRIPT_TEST_H
+#ifndef GDSCRIPT_TEST_RUNNER_H
+#define GDSCRIPT_TEST_RUNNER_H
#include "../gdscript.h"
#include "core/error/error_macros.h"
@@ -123,4 +123,4 @@ public:
} // namespace GDScriptTests
-#endif // GDSCRIPT_TEST_H
+#endif // GDSCRIPT_TEST_RUNNER_H