diff options
author | Nat Goodspeed <nat@lindenlab.com> | 2024-02-29 16:47:42 -0500 |
---|---|---|
committer | Nat Goodspeed <nat@lindenlab.com> | 2024-02-29 16:47:42 -0500 |
commit | 6aee62f2bbdd06cf34c4042317cb52ec3c09570c (patch) | |
tree | b92852f9c9b790fbae1b199c2dd835852ccb79cd /indra/newview/scripts/lua | |
parent | d50d7c50651d5bcaf6f35349e2461351cf91224f (diff) |
Fix wonky Unicode chars from web paste
Diffstat (limited to 'indra/newview/scripts/lua')
-rw-r--r-- | indra/newview/scripts/lua/Queue.lua | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/indra/newview/scripts/lua/Queue.lua b/indra/newview/scripts/lua/Queue.lua index fa8737334c..e178ad9969 100644 --- a/indra/newview/scripts/lua/Queue.lua +++ b/indra/newview/scripts/lua/Queue.lua @@ -2,29 +2,29 @@ local Queue = {} Queue.__index = Queue - + function Queue.new() local self = setmetatable({}, Queue) - + self._first = 0 self._last = -1 self._queue = {} - + return self end - + -- Check if the queue is empty function Queue:IsEmpty() return self._first > self._last end - + -- Add a value to the queue function Queue:Enqueue(value) local last = self._last + 1 self._last = last self._queue[last] = value end - + -- Remove a value from the queue function Queue:Dequeue() local first = self._first @@ -36,5 +36,5 @@ function Queue:Dequeue() self._first = first + 1 return value end - + return Queue |