Open
Description
Issue description:
The compiler doesn't detect variables as unused if they're read/written from an unused function.
new some_var;
stock GetVar()
return some_var;
main(){}
I think we should consider this a bug and not an intended behavior, because if the user didn't want any warnings about the variable being unused, they could just define it with the stock
specifier (new stock some_var;
or stock some_var;
).
Minimal complete verifiable example (MCVE):
See above.
Workspace Information:
- Compiler version: 3.10.10, 3.2.3664
- Command line arguments provided (or sampctl version):
- Operating System:
Special thanks to user DeimoS from the pro-pawn.ru forums who originally discovered this bug.