Don't declare public constants as constants

Public constants must be declared as variables, like it was done
before the previous commit, because they must be visible by the
amx_XXXPubVar API.
This commit is contained in:
Zeex 2015-06-20 09:59:24 +06:00
parent 39828f23f2
commit 88f78aa882

View File

@ -1861,7 +1861,7 @@ static void declfuncvar(int fpublic,int fstatic,int fstock,int fconst)
invalidfunc= fconst || (fpublic && fstock);
if (invalidfunc || !newfunc(name,tag,fpublic,fstatic,fstock)) {
/* if not a function, try a global constant/variable */
if (fconst) {
if (fconst && !fpublic) {
lexpush();
decl_const(sGLOBAL);
} else {