diff --git a/coord/ops.hpp b/coord/ops.hpp index 4ae47ad3..5ce9b01c 100644 --- a/coord/ops.hpp +++ b/coord/ops.hpp @@ -19,8 +19,9 @@ #include "./fwd.hpp" -#include "../preprocessor.hpp" +#include "../debug.hpp" #include "../maths.hpp" +#include "../preprocessor.hpp" #include "../types/bits.hpp" #include @@ -489,7 +490,10 @@ namespace util { K normalised (const K &k) { - return k / norm (k); + auto n = norm (k); + CHECK_NEZ (n); + + return k / n; }