-
Notifications
You must be signed in to change notification settings - Fork 72
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Misc. fixes and improvements for unused assignment detection #679
base: dev
Are you sure you want to change the base?
Conversation
…while loop, so the code inside the loop condition won't be mixed with the code inside the loop body
… on a label defined after the use, inside of the same loop MCVE: ``` main() { for (new x = 5; --x != 0;) { if (x == 2) { x = 1; goto lbl_cont; } x = 3; // false-positive warning 240 lbl_cont: } } ```
This issue has been automatically marked as stale because it has not had recent activity. |
It would be good if REMOTE_FUNC__ static void:yrt_7(&a, &b, c, &d)
{
//print("yrt_7 called");
a = 8;
b = a;
c += d;
d -= 4;
#pragma unused c
} I get a warning on the |
@Y-Less Thanks, I forgot to reset the "modified" flag when using |
What this PR does / why we need it:
This PR does the following:
++
,--
, and compound assignment operators (+=
,-=
,*=
etc,)goto
is used inside of a loop, on a label defined after the use, inside of the same loop (see Another warning 240 false positive. #669 (comment)).Which issue(s) this PR fixes:
Fixes #669
What kind of pull this is:
Additional Documentation: