0

Regarding eclipse Kepler SR1

Hi,

I remember that a unused private methods were getting a warning from the compiler.

I don't know if it's changed switching to Kepler (or a previous release) or if it is project settings, because I'm working on a new project where the eclipse settings are shared.

I even couldn't find the setting in the eclipse compiler settings.

keiki
  • 3,260
  • 3
  • 30
  • 38

5 Answers5

2

go to your project on "Package Explorer", right-click on it and choose "properties". Then inside properties "Java Compiler", "Errors/Warnings". Check the box with "Enable project specific settings". Scroll down to the section where it says "Unnecessary code" and check them to "Warning"

Luis Matos
  • 347
  • 3
  • 14
  • There are project specific settings (shared using version control system), where many things are ignored. Thank you for pointing that out. – keiki Nov 15 '13 at 12:03
1

The setting is Preferences > Java > Compiler > Errors/Warnings > Unnecessary code > Unused private member.

greg-449
  • 109,219
  • 232
  • 102
  • 145
1

Go to

Windows --> Preferences --> Java --> Compiler --> Errors/Warnings

Under Unnecessary Code section you can find Unused private member

Change it to Warning

Sandhu Santhakumar
  • 1,678
  • 1
  • 13
  • 24
0

It could be your company/ project uses other eclipse plugins which allow code analysis with lets say sonar and the eclipse static code analysis thatfore has been fully disabled.

I am still using the Indigo version of eclipse but i assume you can see what youre looking for under Window->Preferences->Java->Compiler->Errors/Warnings

JBA
  • 2,769
  • 5
  • 24
  • 40
0

Change settings from preferences. Here is some illustration.Warning_error

Nishant
  • 1,142
  • 1
  • 9
  • 27