Peter H. Froehlich 8 年之前
父节点
当前提交
ab0ff611a6
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      queue/queue.go

+ 2 - 2
queue/queue.go

@@ -89,14 +89,14 @@ func (q *Queue) resize(size int) {
 // lazyGrow grows the underlying slice if necessary.
 func (q *Queue) lazyGrow() {
 	if q.full() {
-		q.resize(len(q.rep)*2)
+		q.resize(len(q.rep) * 2)
 	}
 }
 
 // lazyShrink shrinks the underlying slice if advisable.
 func (q *Queue) lazyShrink() {
 	if q.sparse() {
-		q.resize(len(q.rep)/2)
+		q.resize(len(q.rep) / 2)
 	}
 }