I believe EnableExplicit must warn also for unused declared variables.
As stated here in "weaker points" as well:
http://web.newsguy.com/lmgava/purebasic/about/index.php
Defined but unused variables are not reported at the end of the compilation. This pose the risk of forgetting a variable or maybe even an array or something bigger inside a procedure because you modify it and forget to remove a variable no more referenced.
And it makes full-sense of EnableExplicit.
EnableExplicit : Warning for unused declared variables
EnableExplicit : Warning for unused declared variables
Last edited by charvista on Sat Nov 23, 2013 1:16 am, edited 1 time in total.
- Windows 11 Home 64-bit
- PureBasic 6.10 LTS (x64)
- 64 Gb RAM
- 13th Gen Intel(R) Core(TM) i9-13900K 3.00 GHz
- 5K monitor with DPI @ 200%
- PureBasic 6.10 LTS (x64)
- 64 Gb RAM
- 13th Gen Intel(R) Core(TM) i9-13900K 3.00 GHz
- 5K monitor with DPI @ 200%
Re: EnableExplicit : Warning for unused declared variables
Hey ! I'm innocent, I don't have nothing to do with it ! I don't even know him !#$%!@*! 
EDIT:
Just found this post by chance 4 years later.
I bet there are tons of dead variables in PB programs at this very moment waiting to be reported ...

EDIT:
Just found this post by chance 4 years later.
I bet there are tons of dead variables in PB programs at this very moment waiting to be reported ...
Last edited by luis on Sun Jan 07, 2018 2:31 pm, edited 1 time in total.
"Have you tried turning it off and on again ?"
A little PureBasic review
A little PureBasic review
-
- Always Here
- Posts: 6426
- Joined: Fri Oct 23, 2009 2:33 am
- Location: Wales, UK
- Contact:
Re: EnableExplicit : Warning for unused declared variables
+ 1
IdeasVacuum
If it sounds simple, you have not grasped the complexity.
If it sounds simple, you have not grasped the complexity.