MCPcopy Create free account
hub / github.com/GDRETools/gdsdecomp / get_token_identifier

Method get_token_identifier

bytecode/gdscript_v1_tokenizer_compat.cpp:1022–1029  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1020}
1021
1022StringName GDScriptV1TokenizerTextCompat::get_token_identifier(int p_offset) const {
1023 ERR_FAIL_COND_V(p_offset <= -MAX_LOOKAHEAD, StringName());
1024 ERR_FAIL_COND_V(p_offset >= MAX_LOOKAHEAD, StringName());
1025
1026 int ofs = (TK_RB_SIZE + tk_rb_pos + p_offset - MAX_LOOKAHEAD - 1) % TK_RB_SIZE;
1027 ERR_FAIL_COND_V(tk_rb[ofs].type != T::G_TK_IDENTIFIER, StringName());
1028 return tk_rb[ofs].literal;
1029}
1030
1031int GDScriptV1TokenizerTextCompat::get_token_built_in_func(int p_offset) const {
1032 ERR_FAIL_COND_V(p_offset <= -MAX_LOOKAHEAD, decomp->get_function_count());

Callers 1

parse_code_stringMethod · 0.45

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected