julia> @finch_code begin
        z2 .= 0
        for i = _
            z2[] += y[i]
        end
    end
quote
    z2 = (ex.bodies[1]).tns.bind
    y_lvl = (ex.bodies[2]).body.rhs.tns.bind.lvl
    y_lvl_ptr = y_lvl.ptr
    y_lvl_left = y_lvl.left
    y_lvl_right = y_lvl.right
    y_lvl_val = y_lvl.lvl.val
    z2_val = 0
    y_lvl_q = y_lvl_ptr[1]
    y_lvl_q_stop = y_lvl_ptr[1 + 1]
    if y_lvl_q < y_lvl_q_stop
        y_lvl_i_end = y_lvl_right[y_lvl_q_stop - 1]
    else
        y_lvl_i_end = 0.0f0
    end
    phase_stop = min(y_lvl_i_end, y_lvl.shape)
    if phase_stop >= limit(1.0)
        i = limit(1.0)
        if y_lvl_right[y_lvl_q] < limit(1.0)
            y_lvl_q = Finch.scansearch(y_lvl_right, limit(1.0), y_lvl_q, y_lvl_q_stop - 1)
        end
        while true
            i_start_2 = i
            y_lvl_i_start = y_lvl_left[y_lvl_q]
            y_lvl_i_stop = y_lvl_right[y_lvl_q]
            if y_lvl_i_stop < phase_stop
                phase_start_3 = max(i_start_2, y_lvl_i_start)
                if y_lvl_i_stop >= phase_start_3
                    y_lvl_2_val = y_lvl_val[y_lvl_q]
                    cond = -phase_start_3 + y_lvl_i_stop == 0
                    if cond
                        z2_val = y_lvl_2_val + z2_val
                    end
                end
                y_lvl_q += y_lvl_i_stop == y_lvl_i_stop
                i = y_lvl_i_stop + limit(0+ϵ)
            else
                phase_start_4 = i
                phase_stop_5 = min(y_lvl_i_stop, phase_stop)
                phase_start_6 = max(y_lvl_i_start, phase_start_4)
                if phase_stop_5 >= phase_start_6
                    y_lvl_2_val_2 = y_lvl_val[y_lvl_q]
                    cond_2 = -phase_start_6 + phase_stop_5 == 0
                    if cond_2
                        z2_val = z2_val + y_lvl_2_val_2
                    end
                end
                y_lvl_q += phase_stop_5 == y_lvl_i_stop
                i = phase_stop_5 + limit(0+ϵ)
                break
            end
        end
    end
    (z2 = (Scalar){0, Int64}(z2_val),)
end
julia> @finch begin
        z2 .= 0
        for i = _
            z2[] += y[i]
        end
    end
(z2 = Scalar{0, Int64}(20),)

