From 4c5832a0be947baf786e9a7185634bace3ac8382 Mon Sep 17 00:00:00 2001 From: Kevin Grant Date: Sat, 14 Feb 2015 20:53:35 -0800 Subject: [PATCH] Fix bug in ValueIteratorBase::operator- --- include/json/value.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/json/value.h b/include/json/value.h index 0c507a3..62a323b 100644 --- a/include/json/value.h +++ b/include/json/value.h @@ -946,7 +946,7 @@ public: bool operator!=(const SelfType& other) const { return !isEqual(other); } difference_type operator-(const SelfType& other) const { - return computeDistance(other); + return other.computeDistance(*this); } /// Return either the index or the member name of the referenced value as a