public String findTask(final XtextResource res, final int offset) {
if ((offset < 0)) {
return null;
}
IParseResult _parseResult = res.getParseResult();
ICompositeNode _rootNode = _parseResult.getRootNode();
final ILeafNode start = NodeModelUtils.findLeafNodeAtOffset(_rootNode, offset);
boolean _isHidden = start.isHidden();
if (_isHidden) {
IParseResult _parseResult_1 = res.getParseResult();
ICompositeNode _rootNode_1 = _parseResult_1.getRootNode();
Iterable<ILeafNode> _leafNodes = _rootNode_1.getLeafNodes();
final List<ILeafNode> list = IterableExtensions.<ILeafNode>toList(_leafNodes);
final int index = list.indexOf(start);
IntegerRange _upTo = new IntegerRange(index, 0);
final Function1<Integer, Boolean> _function = new Function1<Integer, Boolean>() {