JDK-4728434 : Deprecated warnings are not given if the class containing the tag is compiled at
  • Type: Bug
  • Component: tools
  • Sub-Component: javac
  • Affected Version: 1.4.0
  • Priority: P4
  • Status: Closed
  • Resolution: Duplicate
  • OS: windows_2000
  • CPU: x86
  • Submitted: 2002-08-08
  • Updated: 2002-08-08
  • Resolved: 2002-08-08
Related Reports
Duplicate :  
Description

Name: pa48320			Date: 08/08/2002

If you compile a bunch on files at the same time and one containes the @deprecated tag and another uses that method, you will not get the deprecated warning. Consider the following two classes:
package com.test;
public class test1
{
	/**
	 * @deprecated
	 */
	
	public void method1()
	{
		System.out.println("method1");
	}
}

package com.test;

public class test2
{

	public void method2()
	{
		test1 t = new test1();
		t.method1();

	}
}

Compile them using javac *.java. You get no warnings. Modify test2 and recompile just test2.java. You will get the deprecated warnings.
======================================================================

Comments
WORK AROUND Name: pa48320 Date: 08/08/2002 Only compile files individually. ======================================================================
11-06-2004

PUBLIC COMMENTS ...
10-06-2004