diff --git a/source/compiler/sc1.c b/source/compiler/sc1.c index 7bf8a55..751f65d 100644 --- a/source/compiler/sc1.c +++ b/source/compiler/sc1.c @@ -1860,13 +1860,8 @@ static void declfuncvar(int fpublic,int fstatic,int fstock,int fconst) /* only variables can be "const" or both "public" and "stock" */ invalidfunc= fconst || (fpublic && fstock); if (invalidfunc || !newfunc(name,tag,fpublic,fstatic,fstock)) { - /* if not a function, try a global constant/variable */ - if (fconst && !fpublic) { - lexpush(); - decl_const(sGLOBAL); - } else { - declglb(name,tag,fpublic,fstatic,fstock,fconst); - } /* if */ + /* if not a function, try a global variable */ + declglb(name,tag,fpublic,fstatic,fstock,fconst); } /* if */ } /* if */ } @@ -4953,14 +4948,8 @@ static void statement(int *lastindent,int allow_decl) break; case tSTATIC: if (allow_decl) { - tok=lex(&val,&st); - if (tok==tCONST) { - decl_const(sSTATIC); - } else { - lexpush(); - declloc(TRUE); - lastst=tNEW; - } /* if */ + declloc(TRUE); + lastst=tNEW; } else { error(3); /* declaration only valid in a block */ } /* if */