Style: Integrate #pragma once in builders/checks
This commit is contained in:
@ -78,8 +78,7 @@ def main():
|
||||
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
|
||||
/**************************************************************************/
|
||||
|
||||
#ifndef TEST_{name_upper_snake_case}_H
|
||||
#define TEST_{name_upper_snake_case}_H
|
||||
#pragma once
|
||||
|
||||
#include "tests/test_macros.h"
|
||||
|
||||
@ -90,14 +89,11 @@ TEST_CASE("[{name_pascal_case}] Example test case") {{
|
||||
}}
|
||||
|
||||
}} // namespace Test{name_pascal_case}
|
||||
|
||||
#endif // TEST_{name_upper_snake_case}_H
|
||||
""".format(
|
||||
name_snake_case=name_snake_case,
|
||||
# Capitalize the first letter but keep capitalization for the rest of the string.
|
||||
# This is done in case the user passes a camelCase string instead of PascalCase.
|
||||
name_pascal_case=args.name[0].upper() + args.name[1:],
|
||||
name_upper_snake_case=name_snake_case.upper(),
|
||||
# The padding length depends on the test name length.
|
||||
padding=" " * (61 - len(name_snake_case)),
|
||||
)
|
||||
|
||||
@ -1,6 +1,5 @@
|
||||
/* WARNING, THIS FILE WAS GENERATED, DO NOT EDIT */
|
||||
#ifndef VERTEX_FRAGMENT_GLSL_GEN_HGLES3_GLES3
|
||||
#define VERTEX_FRAGMENT_GLSL_GEN_HGLES3_GLES3
|
||||
#pragma once
|
||||
|
||||
|
||||
#include "drivers/gles3/shader_gles3.h"
|
||||
@ -70,5 +69,3 @@ void main() {
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
@ -1,6 +1,5 @@
|
||||
/* WARNING, THIS FILE WAS GENERATED, DO NOT EDIT */
|
||||
#ifndef COMPUTE_SHADER_GLSL_RAW_H
|
||||
#define COMPUTE_SHADER_GLSL_RAW_H
|
||||
#pragma once
|
||||
|
||||
static const char compute_shader_glsl[] = {
|
||||
R"<!>(#[compute]
|
||||
@ -17,4 +16,3 @@ void main() {
|
||||
}
|
||||
)<!>"
|
||||
};
|
||||
#endif
|
||||
|
||||
@ -1,6 +1,5 @@
|
||||
/* WARNING, THIS FILE WAS GENERATED, DO NOT EDIT */
|
||||
#ifndef VERTEX_FRAGMENT_SHADER_GLSL_RAW_H
|
||||
#define VERTEX_FRAGMENT_SHADER_GLSL_RAW_H
|
||||
#pragma once
|
||||
|
||||
static const char vertex_fragment_shader_glsl[] = {
|
||||
R"<!>(#[versions]
|
||||
@ -37,4 +36,3 @@ void main() {
|
||||
}
|
||||
)<!>"
|
||||
};
|
||||
#endif
|
||||
|
||||
@ -1,6 +1,5 @@
|
||||
/* WARNING, THIS FILE WAS GENERATED, DO NOT EDIT */
|
||||
#ifndef COMPUTE_GLSL_GEN_H_RD
|
||||
#define COMPUTE_GLSL_GEN_H_RD
|
||||
#pragma once
|
||||
|
||||
#include "servers/rendering/renderer_rd/shader_rd.h"
|
||||
|
||||
@ -28,5 +27,3 @@ void main() {
|
||||
setup(nullptr, nullptr, _compute_code, "ComputeShaderRD");
|
||||
}
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
@ -1,6 +1,5 @@
|
||||
/* WARNING, THIS FILE WAS GENERATED, DO NOT EDIT */
|
||||
#ifndef VERTEX_FRAGMENT_GLSL_GEN_H_RD
|
||||
#define VERTEX_FRAGMENT_GLSL_GEN_H_RD
|
||||
#pragma once
|
||||
|
||||
#include "servers/rendering/renderer_rd/shader_rd.h"
|
||||
|
||||
@ -42,5 +41,3 @@ void main() {
|
||||
setup(_vertex_code, _fragment_code, nullptr, "VertexFragmentShaderRD");
|
||||
}
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user