mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2025-01-19 07:20:50 +00:00
[vulkan] Add a comment about using size_t
Due to wanting to access array sizes when parsing uint32_t type values, parse_uint32_t needs to handle size_t values even though it throws out any excess bits.
This commit is contained in:
parent
4bda49d798
commit
b08c3881b9
1 changed files with 3 additions and 1 deletions
|
@ -182,9 +182,11 @@ parse_uint32_t (const plfield_t *field, const plitem_t *item,
|
|||
void *data, plitem_t *messages, void *context)
|
||||
{
|
||||
int ret = 1;
|
||||
// use size_t (and cexpr_size_t) for val so references to array sizes
|
||||
// can be used
|
||||
size_t val = 0;
|
||||
exprctx_t ectx = *((parsectx_t *) context)->ectx;
|
||||
exprval_t result = { &cexpr_size_t, &val };
|
||||
exprctx_t ectx = *((parsectx_t *) context)->ectx;
|
||||
ectx.symtab = 0;
|
||||
ectx.result = &result;
|
||||
const char *valstr = PL_String (item);
|
||||
|
|
Loading…
Reference in a new issue