From 814b610ed3884d7879b60aadd09d66b3e3102357 Mon Sep 17 00:00:00 2001 From: Marcelo Fernandez Date: Thu, 22 Mar 2018 13:26:04 -0300 Subject: [PATCH] Fix for clang warning at distance_to (cherry picked from commit bbd21c22030c85d098fa79ee69f78803a86c15ba) --- core/math/math_2d.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/math/math_2d.h b/core/math/math_2d.h index 8928349a448..cdfd90747b1 100644 --- a/core/math/math_2d.h +++ b/core/math/math_2d.h @@ -304,7 +304,7 @@ struct Rect2 { inline real_t distance_to(const Vector2 &p_point) const { - real_t dist; + real_t dist = 0.0; bool inside = true; if (p_point.x < position.x) {