diff options
author | Dmitrii Maganov <vonagam@gmail.com> | 2023-01-12 20:18:23 +0200 |
---|---|---|
committer | Dmitrii Maganov <vonagam@gmail.com> | 2023-01-13 15:36:11 +0200 |
commit | 40613ebd21263678ccca63d79bd0853e5d77cca4 (patch) | |
tree | 58d7727924f048d0dedcae641d7e081a9ec6af55 /core | |
parent | 3c9bf4bc210a8e6a208f30ca59de4d4d7e18c04d (diff) |
GDScript: Fix typing of iterator in for loop
Diffstat (limited to 'core')
-rw-r--r-- | core/variant/variant_setget.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/core/variant/variant_setget.cpp b/core/variant/variant_setget.cpp index b8d4495702..a74556d88f 100644 --- a/core/variant/variant_setget.cpp +++ b/core/variant/variant_setget.cpp @@ -1253,7 +1253,7 @@ bool Variant::iter_init(Variant &r_iter, bool &valid) const { return _data._int > 0; } break; case FLOAT: { - r_iter = 0; + r_iter = 0.0; return _data._float > 0.0; } break; case VECTOR2: { @@ -1457,7 +1457,7 @@ bool Variant::iter_next(Variant &r_iter, bool &valid) const { return true; } break; case FLOAT: { - int64_t idx = r_iter; + double idx = r_iter; idx++; if (idx >= _data._float) { return false; |