From 47d113696dd545933b818772f5e2cd7534947484 Mon Sep 17 00:00:00 2001 From: Nilay Vaish Date: Fri, 6 Sep 2013 16:21:29 -0500 Subject: stats: adds a Formula operator for division --- src/base/statistics.cc | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'src/base/statistics.cc') diff --git a/src/base/statistics.cc b/src/base/statistics.cc index 630205a59..0b44a4ec7 100644 --- a/src/base/statistics.cc +++ b/src/base/statistics.cc @@ -387,6 +387,16 @@ Formula::operator+=(Temp r) return *this; } +const Formula & +Formula::operator/=(Temp r) +{ + assert (root); + root = NodePtr(new BinaryNode >(root, r)); + + assert(size()); + return *this; +} + void Formula::result(VResult &vec) const { -- cgit v1.2.3