diff options
author | John Wiegley <johnw@newartisans.com> | 2020-11-03 16:25:18 -0800 |
---|---|---|
committer | John Wiegley <johnw@newartisans.com> | 2022-02-03 09:01:18 -0800 |
commit | bc45e0205d23f5a8f2e3e389195daa85f4b07ec0 (patch) | |
tree | 2161b65b84611da15073d280d3d62ffac3939cb1 /src | |
parent | c99a4b03320242d3d5a6d64f73f8581fe5ea2306 (diff) | |
download | fork-ledger-bc45e0205d23f5a8f2e3e389195daa85f4b07ec0.tar.gz fork-ledger-bc45e0205d23f5a8f2e3e389195daa85f4b07ec0.tar.bz2 fork-ledger-bc45e0205d23f5a8f2e3e389195daa85f4b07ec0.zip |
Revert "Revert "Compare price annotations using their textual rendering""
This reverts commit 7f78cadea4a2359f1f53ce9c0c66b6d3fafd81c4.
Diffstat (limited to 'src')
-rw-r--r-- | src/annotate.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/annotate.h b/src/annotate.h index 75d42589..c670f8cc 100644 --- a/src/annotate.h +++ b/src/annotate.h @@ -91,7 +91,9 @@ struct annotation_t : public supports_flags<>, bool operator<(const annotation_t& rhs) const; bool operator==(const annotation_t& rhs) const { - return (price == rhs.price && + return (((! price && ! rhs.price) || + (price && rhs.price && + (*price).to_string() == (*rhs.price).to_string())) && date == rhs.date && tag == rhs.tag && (value_expr && rhs.value_expr ? |