Community
Participate
Working Groups
public class A { void f(boolean flag){ boolean a; //<<<incorrect 'variable never used' warning if (flag) a= true; else a= false; } }
I think 'never used' means that the value of this variable is never used. In your example, you store a value in 'a', but you never read the value from 'a'. Then this variable is useless.
it's only a wording problem then. would 'variable never read' be better? for me, 'used' means 'read or assigned to'
It is a wording problem.
Fixed error message wording.