SA-MP Forums Archive
6 weird 219 warnings - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: 6 weird 219 warnings (/showthread.php?tid=556939)



[NOT SOLVED]6 weird 219 warnings - CalvinC - 12.01.2015

Im getting at total 6 219 warnings: local variable "string" shadows a variable at a preceding level.
Some of them from ridiculous places, some has several warnings at one place, there's no global "new string" or anything like that.

pawn Code:
Removed
pawn Code:
Removed
pawn Code:
Removed
EDIT: Fixed.


Re: 6 weird 219 warnings - Rudy_ - 12.01.2015

Can you show me all the errors, and the lines of errors?
Code:
 local variable "string" shadows a variable at a preceding level.
It means you've created a new variable 'string' 2 times, Like maybe one global and one with the same name inside a callback. just change the string to astring or str or anyting else..


Re: 6 weird 219 warnings - CalvinC - 12.01.2015

I already showed the lines with errors, and as you can see they're not global, some of them aren't even string-variables.


Re: 6 weird 219 warnings - Beckett - 12.01.2015

Show the entire callback perhaps you are missing a bracket and post the errors.


Re: 6 weird 219 warnings - CalvinC - 12.01.2015

All warnings are "local variable "string" shadows a variable at a preceding level", as i said in the first post.
There's none other.
pawn Code:
Removed
The first 4 warnings above seems to be always at the same lines, which can change when i edit the script.

Although the 2 warnings below have stayed, so they may be the "real" ones i guess, since the above doesn't make sense either.
pawn Code:
Removed



Re: 6 weird 219 warnings - CalvinC - 13.01.2015

Bump, and update.
I tried a bracket program online too, found no missing brackets, and same amount of starting and closing brackets.


Re: 6 weird 219 warnings - PowerPC603 - 13.01.2015

Do you have a "string" field in one of your enums?
Those count as global variables as well.


Re: 6 weird 219 warnings - CalvinC - 13.01.2015

I know, i don't have any strings in my enums.


Re: 6 weird 219 warnings - CalvinC - 13.01.2015

I just realised that the 4 first errors are from the sscanf2 include, although i haven't edited, and it used to be fine?


Re: 6 weird 219 warnings - CalvinC - 14.01.2015

Bump.