def find_inner_paragraph(view, initial_loc):
    # Determine whether the initial point lies in an all-whitespace line.
    is_whitespace = lambda region: len(view.substr(region).strip()) == 0
    iws = is_whitespace(view.line(initial_loc))

    # Search backward finding all lines with similar whitespace status.
    # This will give use the value for begin.
    p = initial_loc
    while True:
        line = view.line(p)
        if is_whitespace(line) != iws:
            break
        elif line.begin() == 0:
            p = 0
            break
        p = line.begin() - 1
    begin = p + 1 if p > 0 else p

    # To get the value for end, we do the same thing, this time searching forward.
    p = initial_loc
    while True:
        line = view.line(p)
        if is_whitespace(line) != iws:
            break
        p = line.end() + 1
        if p >= view.size():
            break
    end = p

    return (begin, end)

# TODO: Move this to units.py.
template_arglist : template_argument
dataset/ETHPy150Open guillermooo/Vintageous/vi/text_objects.py/find_inner_paragraph--crossover with--dataset/ETHPy150Open nucleic/enaml/enaml/core/parser.py/p_template_arglist1