- changed status to resolved
Clone overriding error
Issue #165
resolved
The following piece of code does not compile :
package p;
interface LogEntry {
public LogEntry clone();
}
abstract class BaseEntry implements LogEntry {
@Override
public LogEntry clone(){
try{
return (LogEntry)super.clone();
} catch (CloneNotSupportedException e) {
throw new Error();
}
}
}
class INLogEntry extends BaseEntry implements LogEntry {}
Comments (2)
-
-
reporter Nice ! thank you very much
- Log in to comment
Improve method override compatibility checking
fixes
#165(bitbucket)→ <<cset bd81539b8e15>>