That's a good question - my guess is that it's that way due to the expense of doing code path analysis for a class against inline code. If you declare a class with an uninitialised public member...
Type: Posts; User: Sean4u
That's a good question - my guess is that it's that way due to the expense of doing code path analysis for a class against inline code. If you declare a class with an uninitialised public member...
There's no such thing as a 'final int', only a final variable or a final method. A final method is one that cannot be overridden, not one that guarantees its return value. I'd say javac is defensibly...
I'm glad you got working code in the end, but your solution is a "belt and braces" kludge. The compiler analyses your code to warn you of routes through your code where your variables may be used...
It's doing code path analysis. There's a path through your code where you access the value of af and it may not ever have been assigned. Try walking through your code in your mind - you'll soon spot...