if (completionData == null) {
completionData = getCompletionData(context, lastElement);
}
if (completionData == null) return new LookupData(new LookupItem[0], context.getPrefix());
final Set<LookupItem> lookupSet = new LinkedHashSet<LookupItem>();
<BUG>complete(context, insertedElement, completionData, lookupSet);
final Set<CompletionVariant> keywordVariants = new HashSet<CompletionVariant>();</BUG>
completionData.addKeywordVariants(keywordVariants, context, insertedElement);
CompletionData.completeKeywordsBySet(lookupSet, keywordVariants, context, insertedElement);
<BUG>CompletionUtil.highlightMembersOfContainer(lookupSet);
final LookupItem[] items = lookupSet.toArray(new LookupItem[lookupSet.size()]);</BUG>
final LookupData data = new LookupData(items, context.getPrefix());

if (completionData == null) {
completionData = getCompletionData(context, lastElement);
}
if (completionData == null) return new LookupData(new LookupItem[0], context.getPrefix());
final Set<LookupItem> lookupSet = new LinkedHashSet<LookupItem>();
complete(context, insertedElement, completionData, lookupSet);
if (lookupSet.size() == 0 || !CodeInsightUtil.isAntFile(file)) {
final Set<CompletionVariant> keywordVariants = new HashSet<CompletionVariant>();
completionData.addKeywordVariants(keywordVariants, context, insertedElement);
CompletionData.completeKeywordsBySet(lookupSet, keywordVariants, context, insertedElement);
CompletionUtil.highlightMembersOfContainer(lookupSet);
}
final LookupItem[] items = lookupSet.toArray(new LookupItem[lookupSet.size()]);
final LookupData data = new LookupData(items, context.getPrefix());
