aboutsummaryrefslogtreecommitdiff
path: root/include/axolotl/list.hh
diff options
context:
space:
mode:
authorMark Haines <mjark@negativecurvature.net>2015-02-26 16:30:19 +0000
committerMark Haines <mjark@negativecurvature.net>2015-02-26 16:30:19 +0000
commit09d8e84c7cbbf21195f3fd2eabbcff44042d5a4e (patch)
tree73a1f072bf86175c266579089fecb21e83d1d22c /include/axolotl/list.hh
parent186df91246cc61febb398383e4e742973fc9aaf0 (diff)
Implement the axlotl ratchet
Diffstat (limited to 'include/axolotl/list.hh')
-rw-r--r--include/axolotl/list.hh5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/axolotl/list.hh b/include/axolotl/list.hh
index a3c3d01..4c87630 100644
--- a/include/axolotl/list.hh
+++ b/include/axolotl/list.hh
@@ -61,6 +61,11 @@ public:
}
/**
+ * Make space for an item in the list at the start of the list
+ */
+ T * insert() { return insert(begin()); }
+
+ /**
* Insert an item into the list at a given position.
* If inserting the item makes the list longer than max_size then
* the end of the list is discarded.