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:
parent
39828f23f2
commit
88f78aa882
@ -1861,7 +1861,7 @@ static void declfuncvar(int fpublic,int fstatic,int fstock,int fconst)
|
|||||||
invalidfunc= fconst || (fpublic && fstock);
|
invalidfunc= fconst || (fpublic && fstock);
|
||||||
if (invalidfunc || !newfunc(name,tag,fpublic,fstatic,fstock)) {
|
if (invalidfunc || !newfunc(name,tag,fpublic,fstatic,fstock)) {
|
||||||
/* if not a function, try a global constant/variable */
|
/* if not a function, try a global constant/variable */
|
||||||
if (fconst) {
|
if (fconst && !fpublic) {
|
||||||
lexpush();
|
lexpush();
|
||||||
decl_const(sGLOBAL);
|
decl_const(sGLOBAL);
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user