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

Method is_token_func_call

bytecode/bytecode_base.cpp:1228–1238  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1226}
1227
1228bool GDScriptDecomp::is_token_func_call(int p_pos, const Vector<uint32_t> &p_tokens) {
1229 if (p_pos > 0 && get_global_token(p_tokens[p_pos - 1]) == G_TK_PR_FUNCTION) {
1230 return false;
1231 }
1232 // Godot 3.x's parser was VERY DUMB and emitted built-in function tokens for any identifier that shared
1233 // the same name as a built-in function, so we have to check if the next token is a parenthesis open
1234 if (p_pos + 1 >= p_tokens.size() || get_global_token(p_tokens[p_pos + 1]) != G_TK_PARENTHESIS_OPEN) {
1235 return false;
1236 }
1237 return true;
1238}
1239
1240bool GDScriptDecomp::is_token_builtin_func(int p_pos, const Vector<uint32_t> &p_tokens) {
1241 auto curr_token = get_global_token(p_tokens[p_pos]);

Callers 1

parse_scriptMethod · 0.80

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected