summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon MacMullen <simon@rabbitmq.com>2015-02-04 12:10:25 +0000
committerSimon MacMullen <simon@rabbitmq.com>2015-02-04 12:10:25 +0000
commitccc25f1bf21acaef8ae834745ce4c3c42420baa5 (patch)
tree621a093d3cef5fe464ed538333992dbcef4f252e
parentc8563b522add0529708b1bea3956f604845b73a3 (diff)
parentfbf68e455a6ccb5d842b02e175960da8edc08c3a (diff)
downloadrabbitmq-server-git-ccc25f1bf21acaef8ae834745ce4c3c42420baa5.tar.gz
Merge bug26574
-rw-r--r--src/lqueue.erl4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/lqueue.erl b/src/lqueue.erl
index 62f60d5ffb..941941de2e 100644
--- a/src/lqueue.erl
+++ b/src/lqueue.erl
@@ -16,6 +16,10 @@
-module(lqueue).
+%% lqueue implements a subset of Erlang's queue module. lqueues
+%% maintain their own length, so lqueue:len/1
+%% is an O(1) operation, in contrast with queue:len/1 which is O(n).
+
-export([new/0, is_empty/1, len/1, in/2, in_r/2, out/1, out_r/1, join/2,
foldl/3, foldr/3, from_list/1, to_list/1, peek/1, peek_r/1]).