[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v1 04/10] diff-utils: point: fix postfix decrement/increment operator
The postfix increment / decrement operators were implemented by calling
themselves recursively. Fix that by implementing these in terms of their
prefix counter parts.
* include/abg-diff-utils.h: fix postfix dec/inc operator
Signed-off-by: Matthias Maennich <maennich@google.com>
---
include/abg-diff-utils.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/include/abg-diff-utils.h b/include/abg-diff-utils.h
index 4e65fe8fe34b..1c71185e3b03 100644
--- a/include/abg-diff-utils.h
+++ b/include/abg-diff-utils.h
@@ -186,7 +186,7 @@ public:
operator--(int)
{
point tmp(*this);
- (*this)--;
+ --(*this);
return tmp;
}
@@ -194,7 +194,7 @@ public:
operator++(int)
{
point tmp(*this);
- (*this)++;
+ ++(*this);
return tmp;
}
--
2.21.0.392.gf8f6787159e-goog