summaryrefslogtreecommitdiff
path: root/modules/mono/glue
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2019-02-27 09:22:47 +0100
committerGitHub <noreply@github.com>2019-02-27 09:22:47 +0100
commit426a6fdc17227715d397f8c09849ce0673b37e64 (patch)
tree9661566abc64fb26d2f0aeeec1d8fd35d39660f3 /modules/mono/glue
parent0ba75c195efffcb098ac74440ffb0fa9c85d0d96 (diff)
parente5f665c7187b6934a71169cab5075f899150f17a (diff)
Merge pull request #26134 from marxin/fix-Wsign-compare
Fix -Wsign-compare warnings.
Diffstat (limited to 'modules/mono/glue')
-rw-r--r--modules/mono/glue/collections_glue.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/mono/glue/collections_glue.cpp b/modules/mono/glue/collections_glue.cpp
index 0e5747a014..d905810d66 100644
--- a/modules/mono/glue/collections_glue.cpp
+++ b/modules/mono/glue/collections_glue.cpp
@@ -86,7 +86,7 @@ bool godot_icall_Array_Contains(Array *ptr, MonoObject *item) {
}
void godot_icall_Array_CopyTo(Array *ptr, MonoArray *array, int array_index) {
- int count = ptr->size();
+ unsigned int count = ptr->size();
if (mono_array_length(array) < (array_index + count)) {
MonoException *exc = mono_get_exception_argument("", "Destination array was not long enough. Check destIndex and length, and the array's lower bounds.");
@@ -94,7 +94,7 @@ void godot_icall_Array_CopyTo(Array *ptr, MonoArray *array, int array_index) {
return;
}
- for (int i = 0; i < count; i++) {
+ for (unsigned int i = 0; i < count; i++) {
MonoObject *boxed = GDMonoMarshal::variant_to_mono_object(ptr->operator[](i));
mono_array_setref(array, array_index, boxed);
array_index++;