From 95e5fc58341936a087bbb8e569445c045bbdd20e Mon Sep 17 00:00:00 2001 From: Danny Robson Date: Tue, 15 Sep 2015 21:06:23 +1000 Subject: [PATCH] maths: add namespaced wrapper for abs --- maths.hpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/maths.hpp b/maths.hpp index a87ae18c..93ba08fc 100644 --- a/maths.hpp +++ b/maths.hpp @@ -32,6 +32,11 @@ abs (T value) { return value > 0 ? value : -value; } +namespace util { + template T abs (T t) { return ::abs (t); } +} + + //----------------------------------------------------------------------------- // Exponentials template