Mercurial Hosting > luan
comparison lucene/src/luan/modules/lucene/Lucene.luan @ 770:50f279d3f889
minor
author | Franklin Schmidt <fschmidt@gmail.com> |
---|---|
date | Fri, 12 Aug 2016 07:07:14 -0600 |
parents | 99356cfde2f0 |
children |
comparison
equal
deleted
inserted
replaced
769:c5f5b655f1f7 | 770:50f279d3f889 |
---|---|
61 M.instances[index] = nil | 61 M.instances[index] = nil |
62 java_index.close() | 62 java_index.close() |
63 end | 63 end |
64 | 64 |
65 function index.search(query, from, to, sort) | 65 function index.search(query, from, to, sort) |
66 from or error "missing 'from' parameter" | |
67 to or error "missing 'to' parameter" | |
66 local results = {} | 68 local results = {} |
67 local function fn(i,doc_fn) | 69 local function fn(i,doc_fn) |
68 if i >= from then | 70 if i >= from then |
69 results[#results+1] = doc_fn() | 71 results[#results+1] = doc_fn() |
70 end | 72 end |