From: Gerald Pfeifer gerald@pfeifer.com
This is a reserved identifier in C23 and would break with GCC 15 moving to -std=gnu23 (which is C23 plus extensions). --- dlls/jscript/bool.c | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-)
diff --git a/dlls/jscript/bool.c b/dlls/jscript/bool.c index a4bbdec3a80..709a0579c58 100644 --- a/dlls/jscript/bool.c +++ b/dlls/jscript/bool.c @@ -144,16 +144,16 @@ static HRESULT BoolConstr_value(script_ctx_t *ctx, jsval_t vthis, WORD flags, un
switch(flags) { case DISPATCH_CONSTRUCT: { - jsdisp_t *bool; + jsdisp_t *b;
if(!r) return S_OK;
- hres = create_bool(ctx, value, &bool); + hres = create_bool(ctx, value, &b); if(FAILED(hres)) return hres;
- *r = jsval_obj(bool); + *r = jsval_obj(b); return S_OK; }
@@ -172,54 +172,54 @@ static HRESULT BoolConstr_value(script_ctx_t *ctx, jsval_t vthis, WORD flags, un
static HRESULT alloc_bool(script_ctx_t *ctx, jsdisp_t *object_prototype, BoolInstance **ret) { - BoolInstance *bool; + BoolInstance *b; HRESULT hres;
- bool = calloc(1, sizeof(BoolInstance)); - if(!bool) + b = calloc(1, sizeof(BoolInstance)); + if(!b) return E_OUTOFMEMORY;
if(object_prototype) - hres = init_dispex(&bool->dispex, ctx, &Bool_info, object_prototype); + hres = init_dispex(&b->dispex, ctx, &Bool_info, object_prototype); else - hres = init_dispex_from_constr(&bool->dispex, ctx, &BoolInst_info, ctx->bool_constr); + hres = init_dispex_from_constr(&b->dispex, ctx, &BoolInst_info, ctx->bool_constr);
if(FAILED(hres)) { - free(bool); + free(b); return hres; }
- *ret = bool; + *ret = b; return S_OK; }
HRESULT create_bool_constr(script_ctx_t *ctx, jsdisp_t *object_prototype, jsdisp_t **ret) { - BoolInstance *bool; + BoolInstance *b; HRESULT hres;
- hres = alloc_bool(ctx, object_prototype, &bool); + hres = alloc_bool(ctx, object_prototype, &b); if(FAILED(hres)) return hres;
hres = create_builtin_constructor(ctx, BoolConstr_value, L"Boolean", NULL, - PROPF_CONSTR|1, &bool->dispex, ret); + PROPF_CONSTR|1, &b->dispex, ret);
- jsdisp_release(&bool->dispex); + jsdisp_release(&b->dispex); return hres; }
-HRESULT create_bool(script_ctx_t *ctx, BOOL b, jsdisp_t **ret) +HRESULT create_bool(script_ctx_t *ctx, BOOL bval, jsdisp_t **ret) { - BoolInstance *bool; + BoolInstance *b; HRESULT hres;
- hres = alloc_bool(ctx, NULL, &bool); + hres = alloc_bool(ctx, NULL, &b); if(FAILED(hres)) return hres;
- bool->val = b; + b->val = bval;
- *ret = &bool->dispex; + *ret = &b->dispex; return S_OK; }