|
@@ -207,6 +207,7 @@ pkg.head = function(num, seq)
|
207
|
207
|
--
|
208
|
208
|
-- Return first *num* elements from sequence
|
209
|
209
|
--
|
|
210
|
+ if not seq then return seq end
|
210
|
211
|
local result = seq:is_smaller(0) -- HACK to generate empty sequence
|
211
|
212
|
for idx, value in ipairs(seq) do
|
212
|
213
|
if idx > num then break end
|