From 9bce51f651aad297ef9eb6df832bfdaf1de05d84 Mon Sep 17 00:00:00 2001
From: WXL <wl_5969728@163.com>
Date: 星期三, 22 四月 2026 14:27:54 +0800
Subject: [PATCH] 青岛推送
---
node_modules/webpack/lib/util/ArrayQueue.js | 15 ++++++++++-----
1 files changed, 10 insertions(+), 5 deletions(-)
diff --git a/node_modules/webpack/lib/util/ArrayQueue.js b/node_modules/webpack/lib/util/ArrayQueue.js
index f877ca1..d3850ef 100644
--- a/node_modules/webpack/lib/util/ArrayQueue.js
+++ b/node_modules/webpack/lib/util/ArrayQueue.js
@@ -6,10 +6,13 @@
"use strict";
/**
+ * FIFO queue backed by arrays with a reversed dequeue buffer to avoid the cost
+ * of repeated `Array#shift` operations.
* @template T
*/
class ArrayQueue {
/**
+ * Seeds the queue with an optional iterable of items in dequeue order.
* @param {Iterable<T>=} items The initial elements.
*/
constructor(items) {
@@ -26,7 +29,7 @@
}
/**
- * Returns the number of elements in this queue.
+ * Returns the current number of items waiting in either internal buffer.
* @returns {number} The number of elements in this queue.
*/
get length() {
@@ -34,7 +37,7 @@
}
/**
- * Empties the queue.
+ * Removes all pending items from both internal buffers.
*/
clear() {
this._list.length = 0;
@@ -42,7 +45,7 @@
}
/**
- * Appends the specified element to this queue.
+ * Appends an item to the tail of the queue.
* @param {T} item The element to add.
* @returns {void}
*/
@@ -51,7 +54,8 @@
}
/**
- * Retrieves and removes the head of this queue.
+ * Removes and returns the next item in FIFO order, switching to a reversed
+ * buffer when that is cheaper than shifting from the front of the array.
* @returns {T | undefined} The head of the queue of `undefined` if this queue is empty.
*/
dequeue() {
@@ -68,7 +72,8 @@
}
/**
- * Finds and removes an item
+ * Removes the first matching item from whichever internal buffer currently
+ * contains it.
* @param {T} item the item
* @returns {void}
*/
--
Gitblit v1.9.3