diff options
author | Andreas Kling <awesomekling@gmail.com> | 2019-11-03 12:33:51 +0100 |
---|---|---|
committer | Andreas Kling <awesomekling@gmail.com> | 2019-11-03 12:33:51 +0100 |
commit | 8c45891c80081c66be7b2d2c9d966ab6580f34d2 (patch) | |
tree | dc7907f0f0f5ad52241e009ea6e45cc60894e966 /AK/Queue.h | |
parent | 78a744da7768a6ba1ec8a300a504647531e9ce86 (diff) | |
download | serenity-8c45891c80081c66be7b2d2c9d966ab6580f34d2.zip |
AK: Allow overriding the Queue segment size with a template parameter
Diffstat (limited to 'AK/Queue.h')
-rw-r--r-- | AK/Queue.h | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/AK/Queue.h b/AK/Queue.h index 157e07ea07..c75898cb96 100644 --- a/AK/Queue.h +++ b/AK/Queue.h @@ -6,7 +6,7 @@ namespace AK { -template<typename T> +template<typename T, int segment_size = 1000> class Queue { public: Queue() { } @@ -54,8 +54,6 @@ public: } private: - static const int segment_size = 1000; - SinglyLinkedList<OwnPtr<Vector<T, segment_size>>> m_segments; int m_index_into_first { 0 }; int m_size { 0 }; |