Skip to content
Snippets Groups Projects
Commit acddf16e authored by Lioncash's avatar Lioncash
Browse files

common/quaternion: Ensure that w is always initialized

Previously xyz was always being zero initialized due to its constructor,
but w wasn't. Ensures that we always have a deterministic initial state.
parent e75e8b95
No related branches found
No related tags found
No related merge requests found
......@@ -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};
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment