JDK-4916622 : unnecessary warning with cast
  • Type: Bug
  • Component: tools
  • Sub-Component: javac
  • Affected Version: 5.0
  • Priority: P4
  • Status: Closed
  • Resolution: Cannot Reproduce
  • OS: solaris_8
  • CPU: generic
  • Submitted: 2003-09-03
  • Updated: 2005-03-19
  • Resolved: 2005-03-19
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 6
6Resolved
Related Reports
Relates :  
Description
The following cast is safe yet we give a warning:

class X {
    interface CF<S> { }
    interface CG<T> { }
    static class CH<S, T> implements CF<S>, CG<T> { }
    interface CI<S> extends CF<S> { }
    interface CJ<T> extends CG<T> { }
    interface CK<S, T> extends CI<S>, CJ<T> { }
    void f() {
        Object o = (CH<String, Integer>) (CK<String, Integer>) null; // <<pass>> <<todo: cast-infer>>
    }
}

Comments
CONVERTED DATA BugTraq+ Release Management Values COMMIT TO FIX: mustang
08-07-2004

PUBLIC COMMENTS ...
08-07-2004

EVALUATION It would be nice to get this fixed for Tiger. ###@###.### 2003-09-05
05-09-2003