summaryrefslogtreecommitdiff
path: root/modules/mono
diff options
context:
space:
mode:
authorIgnacio Etcheverry <ignalfonsore@gmail.com>2018-10-06 23:05:53 +0200
committerRĂ©mi Verschelde <rverschelde@gmail.com>2018-10-07 11:00:05 +0200
commitc1dad2ae2d3a4bdb5b0dda39d4e7adc4aed6fab6 (patch)
tree0c497ff1ed73dcc2fad81c78a4a9e40c9c46eebd /modules/mono
parent44d82b3a070b7ed8973d9e8bc6e58da1084fc7d1 (diff)
C# bindings generator fixes
- Fix unused bool local for MonoBoolean argument. - Append U to API hashes. Fixes warning: 'integer constant is so large that it is unsigned'
Diffstat (limited to 'modules/mono')
-rw-r--r--modules/mono/editor/bindings_generator.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/modules/mono/editor/bindings_generator.cpp b/modules/mono/editor/bindings_generator.cpp
index 2c3435fc1c..bcf08026bc 100644
--- a/modules/mono/editor/bindings_generator.cpp
+++ b/modules/mono/editor/bindings_generator.cpp
@@ -1269,12 +1269,12 @@ Error BindingsGenerator::generate_glue(const String &p_output_dir) {
output.push_back("namespace GodotSharpBindings\n" OPEN_BLOCK "\n");
output.push_back("uint64_t get_core_api_hash() { return ");
- output.push_back(String::num_uint64(GDMono::get_singleton()->get_api_core_hash()) + "; }\n");
+ output.push_back(String::num_uint64(GDMono::get_singleton()->get_api_core_hash()) + "U; }\n");
output.push_back("#ifdef TOOLS_ENABLED\n"
"uint64_t get_editor_api_hash() { return ");
- output.push_back(String::num_uint64(GDMono::get_singleton()->get_api_editor_hash()) +
- "; }\n#endif // TOOLS_ENABLED\n");
+ output.push_back(String::num_uint64(GDMono::get_singleton()->get_api_editor_hash()) + "U; }\n");
+ output.push_back("#endif // TOOLS_ENABLED\n");
output.push_back("uint32_t get_bindings_version() { return ");
output.push_back(String::num_uint64(BINDINGS_GENERATOR_VERSION) + "; }\n");
@@ -2019,7 +2019,7 @@ void BindingsGenerator::_populate_builtin_type_interfaces() {
// bool
itype = TypeInterface::create_value_type(String("bool"));
- itype.c_arg_in = "&%s";
+ itype.c_arg_in = "&%s_in";
// /* MonoBoolean <---> bool
itype.c_in = "\t%0 %1_in = (%0)%1;\n";
itype.c_out = "\treturn (%0)%1;\n";