public TreeCursor findAt(int line, int column) {
        TreeCursor current = this;

        outer: while (true) {
            for (TreeCursor child : current.getChildren()) {
                TokenTree childTree = child.getTree();
                int startLine = childTree.getStartLine();
                int endLine = childTree.getEndLine();
                int startColumn = childTree.getStartColumn();
                int endColumn = childTree.getEndColumn();
                boolean isMatch = false;
                if (line == startLine && line == endLine) {
                    // Column span checks are exclusive to not match the ends of tokens.
                    isMatch = column >= startColumn && column < endColumn;
                } else if (line == startLine && column >= startColumn) {
                    isMatch = true;
                } else if (line == endLine && column < endColumn) {
                    isMatch = true;
                } else if (line > startLine && line < endLine) {
                    isMatch = true;
                }
                if (isMatch) {
                    current = child;
                    continue outer;
                }
            }
            return current;
        }
    }
Find the innermost tree that contains the given coordinates.

@param line   Line to find.
@param column Column to find.
@return Returns the innermost tree that contains the coordinates.
smithy-syntax/src/main/java/software/amazon/smithy/syntax/TreeCursor.java