summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/gles3/shaders/scene.glsl3
-rw-r--r--editor/project_converter_3_to_4.cpp199
-rw-r--r--misc/hooks/README.md2
-rwxr-xr-xmisc/hooks/pre-commit-clang-format2
4 files changed, 103 insertions, 103 deletions
diff --git a/drivers/gles3/shaders/scene.glsl b/drivers/gles3/shaders/scene.glsl
index 96e357e29e..41a43be3fe 100644
--- a/drivers/gles3/shaders/scene.glsl
+++ b/drivers/gles3/shaders/scene.glsl
@@ -604,8 +604,7 @@ layout(std140) uniform GlobalShaderUniformData { //ubo:1
vec4 global_shader_uniforms[MAX_GLOBAL_SHADER_UNIFORMS];
};
- /* Material Uniforms */
-
+/* Material Uniforms */
#ifdef MATERIAL_UNIFORMS_USED
/* clang-format off */
diff --git a/editor/project_converter_3_to_4.cpp b/editor/project_converter_3_to_4.cpp
index bea865af13..be1022533e 100644
--- a/editor/project_converter_3_to_4.cpp
+++ b/editor/project_converter_3_to_4.cpp
@@ -1044,107 +1044,108 @@ bool ProjectConverter3To4::test_conversion(RegExContainer &reg_container) {
// get_object_of_execution
{
- { String base = "var roman = kieliszek.";
- String expected = "kieliszek.";
- String got = get_object_of_execution(base);
- if (got != expected) {
- ERR_PRINT(vformat("Failed to get proper data from get_object_of_execution. \"%s\" should return \"%s\"(%d), got \"%s\"(%d), instead.", base, expected, expected.size(), got, got.size()));
+ String base = "var roman = kieliszek.";
+ String expected = "kieliszek.";
+ String got = get_object_of_execution(base);
+ if (got != expected) {
+ ERR_PRINT(vformat("Failed to get proper data from get_object_of_execution. \"%s\" should return \"%s\"(%d), got \"%s\"(%d), instead.", base, expected, expected.size(), got, got.size()));
+ }
+ valid = valid && (got == expected);
+ }
+ {
+ String base = "r.";
+ String expected = "r.";
+ String got = get_object_of_execution(base);
+ if (got != expected) {
+ ERR_PRINT(vformat("Failed to get proper data from get_object_of_execution. \"%s\" should return \"%s\"(%d), got \"%s\"(%d), instead.", base, expected, expected.size(), got, got.size()));
+ }
+ valid = valid && (got == expected);
+ }
+ {
+ String base = "mortadela(";
+ String expected = "";
+ String got = get_object_of_execution(base);
+ if (got != expected) {
+ ERR_PRINT(vformat("Failed to get proper data from get_object_of_execution. \"%s\" should return \"%s\"(%d), got \"%s\"(%d), instead.", base, expected, expected.size(), got, got.size()));
+ }
+ valid = valid && (got == expected);
+ }
+ {
+ String base = "var node = $world/ukraine/lviv.";
+ String expected = "$world/ukraine/lviv.";
+ String got = get_object_of_execution(base);
+ if (got != expected) {
+ ERR_PRINT(vformat("Failed to get proper data from get_object_of_execution. \"%s\" should return \"%s\"(%d), got \"%s\"(%d), instead.", base, expected, expected.size(), got, got.size()));
+ }
+ valid = valid && (got == expected);
+ }
+
+ // get_starting_space
+ {
+ String base = "\t\t\t var roman = kieliszek.";
+ String expected = "\t\t\t";
+ String got = get_starting_space(base);
+ if (got != expected) {
+ ERR_PRINT(vformat("Failed to get proper data from get_object_of_execution. \"%s\" should return \"%s\"(%d), got \"%s\"(%d), instead.", base, expected, expected.size(), got, got.size()));
+ }
+ valid = valid && (got == expected);
}
- valid = valid && (got == expected);
-}
-{
- String base = "r.";
- String expected = "r.";
- String got = get_object_of_execution(base);
- if (got != expected) {
- ERR_PRINT(vformat("Failed to get proper data from get_object_of_execution. \"%s\" should return \"%s\"(%d), got \"%s\"(%d), instead.", base, expected, expected.size(), got, got.size()));
- }
- valid = valid && (got == expected);
-}
-{
- String base = "mortadela(";
- String expected = "";
- String got = get_object_of_execution(base);
- if (got != expected) {
- ERR_PRINT(vformat("Failed to get proper data from get_object_of_execution. \"%s\" should return \"%s\"(%d), got \"%s\"(%d), instead.", base, expected, expected.size(), got, got.size()));
- }
- valid = valid && (got == expected);
-}
-{
- String base = "var node = $world/ukraine/lviv.";
- String expected = "$world/ukraine/lviv.";
- String got = get_object_of_execution(base);
- if (got != expected) {
- ERR_PRINT(vformat("Failed to get proper data from get_object_of_execution. \"%s\" should return \"%s\"(%d), got \"%s\"(%d), instead.", base, expected, expected.size(), got, got.size()));
- }
- valid = valid && (got == expected);
-}
-}
-// get_starting_space
-{
- String base = "\t\t\t var roman = kieliszek.";
- String expected = "\t\t\t";
- String got = get_starting_space(base);
- if (got != expected) {
- ERR_PRINT(vformat("Failed to get proper data from get_object_of_execution. \"%s\" should return \"%s\"(%d), got \"%s\"(%d), instead.", base, expected, expected.size(), got, got.size()));
- }
- valid = valid && (got == expected);
-}
-// Parse Arguments
-{
- String line = "( )";
- Vector<String> got_vector = parse_arguments(line);
- String got = "";
- String expected = "";
- for (String &part : got_vector) {
- got += part + "|||";
- }
- if (got != expected) {
- ERR_PRINT(vformat("Failed to get proper data from parse_arguments. \"%s\" should return \"%s\"(%d), got \"%s\"(%d), instead.", line, expected, expected.size(), got, got.size()));
- }
- valid = valid && (got == expected);
-}
-{
- String line = "(a , b , c)";
- Vector<String> got_vector = parse_arguments(line);
- String got = "";
- String expected = "a|||b|||c|||";
- for (String &part : got_vector) {
- got += part + "|||";
- }
- if (got != expected) {
- ERR_PRINT(vformat("Failed to get proper data from parse_arguments. \"%s\" should return \"%s\"(%d), got \"%s\"(%d), instead.", line, expected, expected.size(), got, got.size()));
- }
- valid = valid && (got == expected);
-}
-{
- String line = "(a , \"b,\" , c)";
- Vector<String> got_vector = parse_arguments(line);
- String got = "";
- String expected = "a|||\"b,\"|||c|||";
- for (String &part : got_vector) {
- got += part + "|||";
- }
- if (got != expected) {
- ERR_PRINT(vformat("Failed to get proper data from parse_arguments. \"%s\" should return \"%s\"(%d), got \"%s\"(%d), instead.", line, expected, expected.size(), got, got.size()));
- }
- valid = valid && (got == expected);
-}
-{
- String line = "(a , \"(,),,,,\" , c)";
- Vector<String> got_vector = parse_arguments(line);
- String got = "";
- String expected = "a|||\"(,),,,,\"|||c|||";
- for (String &part : got_vector) {
- got += part + "|||";
- }
- if (got != expected) {
- ERR_PRINT(vformat("Failed to get proper data from parse_arguments. \"%s\" should return \"%s\"(%d), got \"%s\"(%d), instead.", line, expected, expected.size(), got, got.size()));
- }
- valid = valid && (got == expected);
-}
-return valid;
+ // Parse Arguments
+ {
+ String line = "( )";
+ Vector<String> got_vector = parse_arguments(line);
+ String got = "";
+ String expected = "";
+ for (String &part : got_vector) {
+ got += part + "|||";
+ }
+ if (got != expected) {
+ ERR_PRINT(vformat("Failed to get proper data from parse_arguments. \"%s\" should return \"%s\"(%d), got \"%s\"(%d), instead.", line, expected, expected.size(), got, got.size()));
+ }
+ valid = valid && (got == expected);
+ }
+ {
+ String line = "(a , b , c)";
+ Vector<String> got_vector = parse_arguments(line);
+ String got = "";
+ String expected = "a|||b|||c|||";
+ for (String &part : got_vector) {
+ got += part + "|||";
+ }
+ if (got != expected) {
+ ERR_PRINT(vformat("Failed to get proper data from parse_arguments. \"%s\" should return \"%s\"(%d), got \"%s\"(%d), instead.", line, expected, expected.size(), got, got.size()));
+ }
+ valid = valid && (got == expected);
+ }
+ {
+ String line = "(a , \"b,\" , c)";
+ Vector<String> got_vector = parse_arguments(line);
+ String got = "";
+ String expected = "a|||\"b,\"|||c|||";
+ for (String &part : got_vector) {
+ got += part + "|||";
+ }
+ if (got != expected) {
+ ERR_PRINT(vformat("Failed to get proper data from parse_arguments. \"%s\" should return \"%s\"(%d), got \"%s\"(%d), instead.", line, expected, expected.size(), got, got.size()));
+ }
+ valid = valid && (got == expected);
+ }
+ {
+ String line = "(a , \"(,),,,,\" , c)";
+ Vector<String> got_vector = parse_arguments(line);
+ String got = "";
+ String expected = "a|||\"(,),,,,\"|||c|||";
+ for (String &part : got_vector) {
+ got += part + "|||";
+ }
+ if (got != expected) {
+ ERR_PRINT(vformat("Failed to get proper data from parse_arguments. \"%s\" should return \"%s\"(%d), got \"%s\"(%d), instead.", line, expected, expected.size(), got, got.size()));
+ }
+ valid = valid && (got == expected);
+ }
+
+ return valid;
}
// Validate in all arrays if names don't do cyclic renames "Node" -> "Node2D" | "Node2D" -> "2DNode"
diff --git a/misc/hooks/README.md b/misc/hooks/README.md
index 0aaeff8ae3..573f8fe350 100644
--- a/misc/hooks/README.md
+++ b/misc/hooks/README.md
@@ -29,7 +29,7 @@ so they should work out of the box on Linux/macOS.
##### clang-format
- Download LLVM for Windows (version 13 or later) from
- <https://releases.llvm.org/download.html>
+ <https://github.com/llvm/llvm-project/releases>
- Make sure LLVM is added to the `PATH` during installation
##### black
diff --git a/misc/hooks/pre-commit-clang-format b/misc/hooks/pre-commit-clang-format
index fd0213c175..e5cf0c4aa2 100755
--- a/misc/hooks/pre-commit-clang-format
+++ b/misc/hooks/pre-commit-clang-format
@@ -80,7 +80,7 @@ fi
# To get consistent formatting, we recommend contributors to use the same
# clang-format version as CI.
RECOMMENDED_CLANG_FORMAT_MAJOR_MIN="13"
-RECOMMENDED_CLANG_FORMAT_MAJOR_MAX="15"
+RECOMMENDED_CLANG_FORMAT_MAJOR_MAX="16"
if [ ! -x "$CLANG_FORMAT" ] ; then
message="Error: clang-format executable not found. Please install clang-format $RECOMMENDED_CLANG_FORMAT_MAJOR_MAX."