summaryrefslogtreecommitdiff
path: root/src/commodity.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/commodity.h')
-rw-r--r--src/commodity.h16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/commodity.h b/src/commodity.h
index 25397131..f65df1b9 100644
--- a/src/commodity.h
+++ b/src/commodity.h
@@ -222,8 +222,6 @@ protected:
#endif // HAVE_BOOST_SERIALIZATION
};
- static bool symbol_needs_quotes(const string& symbol);
-
shared_ptr<base_t> base;
commodity_pool_t * parent_;
@@ -247,28 +245,31 @@ public:
operator bool() const;
- bool is_annotated() const {
- return annotated;
- }
-
virtual bool operator==(const commodity_t& comm) const {
if (comm.annotated)
return comm == *this;
return base.get() == comm.base.get();
}
+ static bool symbol_needs_quotes(const string& symbol);
+
virtual commodity_t& referent() {
return *this;
}
virtual const commodity_t& referent() const {
return *this;
}
+
+ bool is_annotated() const {
+ return annotated;
+ }
+
virtual commodity_t& strip_annotations(const keep_details_t&) {
return *this;
}
virtual void write_annotations(std::ostream&) const {}
- commodity_pool_t& parent() const {
+ commodity_pool_t& pool() const {
return *parent_;
}
@@ -329,7 +330,6 @@ public:
optional<history_t&> history(const optional<commodity_t&>& commodity);
-public:
// These methods provide a transparent pass-through to the underlying
// base->varied_history object.