Commit 8c2c496
Queue Data Structure (#194)
* feat: add generic thread-safe queue package
- Add Queue[T] with FIFO semantics and dynamic resizing
- Implement circular buffer with O(1) enqueue/dequeue operations
- Support automatic growth (2x) and shrinking (0.5x) based on usage
- Provide thread-safe operations with mutex protection
- Include comprehensive test suite with fuzz testing and benchmarks
- Add complete documentation with examples and API reference
- Update main README.md to include queue package in features table
* Fix: lint issue
* Fix coderabbit issues
* Update queue/helper.go
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Signed-off-by: Dimitrios Kyriakidis Kortsekidis <kwstasnere@gmail.com>
* coderabbit suggestions
* Update queue/EXAMPLES.md
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Signed-off-by: Dimitrios Kyriakidis Kortsekidis <kwstasnere@gmail.com>
* Update queue/EXAMPLES.md
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Signed-off-by: Dimitrios Kyriakidis Kortsekidis <kwstasnere@gmail.com>
* coderabbit suggestions
* Update queue/EXAMPLES.md
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Signed-off-by: Dimitrios Kyriakidis Kortsekidis <kwstasnere@gmail.com>
* Update queue/EXAMPLES.md
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Signed-off-by: Dimitrios Kyriakidis Kortsekidis <kwstasnere@gmail.com>
* Update queue/EXAMPLES.md
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Signed-off-by: Dimitrios Kyriakidis Kortsekidis <kwstasnere@gmail.com>
---------
Signed-off-by: Dimitrios Kyriakidis Kortsekidis <kwstasnere@gmail.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>1 parent b9f8ec1 commit 8c2c496
File tree
6 files changed
+1693
-1
lines changed- queue
6 files changed
+1693
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
69 | 69 | | |
70 | 70 | | |
71 | 71 | | |
| 72 | + | |
72 | 73 | | |
73 | 74 | | |
74 | 75 | | |
| |||
97 | 98 | | |
98 | 99 | | |
99 | 100 | | |
100 | | - | |
| 101 | + | |
101 | 102 | | |
102 | 103 | | |
103 | 104 | | |
| |||
0 commit comments