Explorar o código

Merge pull request #1930 from lioncash/common

common/quaternion: Ensure that w is always initialized
bunnei %!s(int64=7) %!d(string=hai) anos
pai
achega
52726342bd
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/common/quaternion.h

+ 1 - 1
src/common/quaternion.h

@@ -12,7 +12,7 @@ template <typename T>
 class Quaternion {
 public:
     Math::Vec3<T> xyz;
-    T w;
+    T w{};
 
     Quaternion<decltype(-T{})> Inverse() const {
         return {-xyz, w};