// Code generated by re2v, DO NOT EDIT.
//line "codegen/v/recursive_functions/basic.re":1
// re2v $INPUT -o $OUTPUT --recursive-functions

struct State {
    str string
mut:
    cur u32
}


//line "codegen/v/recursive_functions/basic.v":13
fn yy0(mut st State) {
    yych := st.str[st.cur]
    st.cur += 1
    match yych {
        0x31...0x39 { yy2(mut st) }
        else { yy1(mut st) }
    }
}

fn yy1(mut st State) {
//line "codegen/v/recursive_functions/basic.re":19
    panic("error!")
//line "codegen/v/recursive_functions/basic.v":26
}

fn yy2(mut st State) {
    yych := st.str[st.cur]
    match yych {
        0x30...0x39 {
            st.cur += 1
            yy2(mut st)
        }
        else { yy3(mut st) }
    }
}

fn yy3(mut st State) {
//line "codegen/v/recursive_functions/basic.re":18
    return
//line "codegen/v/recursive_functions/basic.v":43
}

fn lex(mut st State) {
    yy0(mut st)
}

//line "codegen/v/recursive_functions/basic.re":20


fn main() {
    mut st := &State{str: "1234\x00", cur: 0}
    lex(mut st)
}
