csv.lua: rename find's second argument 'init' to match the Lua Reference Manual

This commit is contained in:
Geoff Leyland 2014-05-26 17:27:50 +12:00
parent 966ba6722f
commit e18409d73f

View File

@ -179,10 +179,10 @@ local function separated_values_iterator(file, parameters)
-- Find something in the buffer, extending it if necessary -- Find something in the buffer, extending it if necessary
local function find(pattern, offset) local function find(pattern, init)
local first, last, capture local first, last, capture
while true do while true do
first, last, capture = buffer:find(pattern, anchor_pos + offset - 1) first, last, capture = buffer:find(pattern, anchor_pos + init - 1)
-- if we found nothing, or the last character is at the end of the -- if we found nothing, or the last character is at the end of the
-- buffer (and the match could potentially be longer) then read some -- buffer (and the match could potentially be longer) then read some
-- more. -- more.