private void addMatches(final List<ModuleLineFunctionArityRef> chunk) {
final List<Match> l = Lists.newArrayListWithCapacity(chunk.size());
final List<ErlangSearchElement> resultAdded = Lists
.newArrayListWithCapacity(chunk.size());
for (final ModuleLineFunctionArityRef ref : chunk) {
final Match m = SearchUtil.createMatch(ref, pathToModuleMap);
l.add(m);
resultAdded.add((ErlangSearchElement) m.getElement());
}
fSearchResult = (ErlangSearchResult) getSearchResult();
final List<ErlangSearchElement> result = fSearchResult.getResult();
result.addAll(resultAdded);
fSearchResult.setResult(result);