From a488d6ae718f1a1ae50bec604119d8409facb837 Mon Sep 17 00:00:00 2001 From: TimeServ Date: Tue, 7 Jun 2005 04:55:36 +0000 Subject: [PATCH] enum/enumflags fix git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@1081 fc73d0e0-1445-4013-8a0c-d673dee63da5 --- engine/qclib/qcc_pr_comp.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/engine/qclib/qcc_pr_comp.c b/engine/qclib/qcc_pr_comp.c index 54c550007..193e4aa78 100644 --- a/engine/qclib/qcc_pr_comp.c +++ b/engine/qclib/qcc_pr_comp.c @@ -7255,9 +7255,8 @@ void QCC_PR_ParseDefs (char *classname) QCC_PR_Lex(); } } - def = QCC_PR_GetDef(type_float, name, pr_scope, true, 1); - def->constant = true; - G_FLOAT(def->ofs) = v; + def = QCC_MakeFloatDef(v); + pHash_Add(&globalstable, name, def, qccHunkAlloc(sizeof(bucket_t))); v++; if (QCC_PR_CheckToken("}")) @@ -7315,9 +7314,8 @@ void QCC_PR_ParseDefs (char *classname) QCC_PR_ParseWarning(WARN_ENUMFLAGS_NOTBINARY, "enumflags - value %i not a single bit", (int)v); } } - def = QCC_PR_GetDef(type_float, name, pr_scope, true, 1); - def->constant = true; - G_FLOAT(def->ofs) = v; + def = QCC_MakeFloatDef(v); + pHash_Add(&globalstable, name, def, qccHunkAlloc(sizeof(bucket_t))); v*=2; if (QCC_PR_CheckToken("}"))