MCPcopy Create free account
hub / github.com/Tencent/xLua / xlua_unpack_decimal

Function xlua_unpack_decimal

WebGLPlugins/xlua.c:1073–1085  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1071} DECIMAL;
1072
1073LUALIB_API int xlua_unpack_decimal(void *p, int offset, uint8_t *scale, uint8_t *sign, int *hi32, uint64_t *lo64) {
1074 CSharpStruct *css = (CSharpStruct *)p;
1075 if (css->fake_id != -1 || css->len < sizeof(int) * 4) {
1076 return 0;
1077 } else {
1078 DECIMAL *dec = (DECIMAL *)(&(css->data[0]) + offset);
1079 *scale = dec->scale;
1080 *sign = dec->sign;
1081 *hi32 = dec->Hi32;
1082 *lo64 = dec->Lo64;
1083 return 1;
1084 }
1085}
1086
1087LUA_API int xlua_is_eq_str(lua_State *L, int idx, const char* str, int str_len) {
1088 size_t lmsg;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected