You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There's no check if const was already specified, although handlers for other specifiers (&, Tag:, ...) have this kind of check.
As a result, the user can specify const any number of times
Func(constconstconstconst arg) {}
and the compiler would think this is okay, although it clearly isn't.
Minimal complete verifiable example (MCVE):
See above.
Workspace Information:
Compiler version: 3.10.10
Command line arguments provided (or sampctl version): Not relevant.
Operating System: Not relevant.
The text was updated successfully, but these errors were encountered:
Issue description:
While working on an implementation of named-only function arguments (#719), I found an oversight in function
declargs()
.compiler/source/compiler/sc1.c
Lines 4278 to 4282 in 81b4a02
There's no check if
const
was already specified, although handlers for other specifiers (&
,Tag:
,...
) have this kind of check.As a result, the user can specify
const
any number of timesand the compiler would think this is okay, although it clearly isn't.
Minimal complete verifiable example (MCVE):
See above.
Workspace Information:
The text was updated successfully, but these errors were encountered: