summaryrefslogtreecommitdiff
path: root/src/format.h
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2012-03-05 15:42:23 -0600
committerJohn Wiegley <johnw@newartisans.com>2012-03-05 15:42:23 -0600
commite7aaaeab33d77c37efc16d7e97d422407fd497a0 (patch)
tree7a5f55754ee311a07315da40f58cf1c415b2d644 /src/format.h
parentdc9ecc600aa766caa3e7d718b0b8656da4ba1f70 (diff)
downloadfork-ledger-e7aaaeab33d77c37efc16d7e97d422407fd497a0.tar.gz
fork-ledger-e7aaaeab33d77c37efc16d7e97d422407fd497a0.tar.bz2
fork-ledger-e7aaaeab33d77c37efc16d7e97d422407fd497a0.zip
Added boost::noncopyable to format_t and format_t::element_t
Diffstat (limited to 'src/format.h')
-rw-r--r--src/format.h7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/format.h b/src/format.h
index 1b8513bb..60ae2abe 100644
--- a/src/format.h
+++ b/src/format.h
@@ -55,7 +55,7 @@ class format_t : public expr_base_t<string>, public noncopyable
{
typedef expr_base_t<string> base_type;
- struct element_t : public supports_flags<>
+ struct element_t : public supports_flags<>, public noncopyable
{
#define ELEMENT_ALIGN_LEFT 0x01
@@ -65,7 +65,7 @@ class format_t : public expr_base_t<string>, public noncopyable
std::size_t min_width;
std::size_t max_width;
variant<string, expr_t> data;
- shared_ptr<struct element_t> next;
+ scoped_ptr<struct element_t> next;
element_t() throw()
: supports_flags<>(), type(STRING), min_width(0), max_width(0) {
@@ -82,7 +82,6 @@ class format_t : public expr_base_t<string>, public noncopyable
min_width = elem.min_width;
max_width = elem.max_width;
data = elem.data;
- next = elem.next;
}
return *this;
}
@@ -104,7 +103,7 @@ class format_t : public expr_base_t<string>, public noncopyable
void dump(std::ostream& out) const;
};
- shared_ptr<element_t> elements;
+ scoped_ptr<element_t> elements;
public:
static enum elision_style_t {