Skip to content
Snippets Groups Projects
Unverified Commit 16962f1c authored by Acha Bill's avatar Acha Bill Committed by GitHub
Browse files

Update packages/binary/datastructure/queue/queue.go

parent df69d202
Branches
Tags
No related merge requests found
...@@ -39,7 +39,7 @@ func (queue *Queue) Capacity() int { ...@@ -39,7 +39,7 @@ func (queue *Queue) Capacity() int {
} }
// Offer adds an element ot the queue and returns true. // Offer adds an element ot the queue and returns true.
// If the buffer is full, it drops it and returns false. // If the queue is full, it drops it and returns false.
func (queue *Queue) Offer(element interface{}) bool { func (queue *Queue) Offer(element interface{}) bool {
queue.mutex.Lock() queue.mutex.Lock()
defer queue.mutex.Unlock() defer queue.mutex.Unlock()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment