Please use the Apache issue tracking system for new NetBeans issues (https://issues.apache.org/jira/projects/NETBEANS0/issues) !!
Bug 108484 - [push down method] PushDown a method referenced in another class returns an error message
[push down method] PushDown a method referenced in another class returns an e...
Status: RESOLVED DUPLICATE of bug 108482
Product: editor
Classification: Unclassified
Component: Refactoring
6.x
PC Windows XP
: P3 (vote)
: TBD
Assigned To: issues@java
issues@java
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2007-06-29 01:00 UTC by kely_garcia
Modified: 2007-08-09 21:49 UTC (History)
0 users

See Also:
Issue Type: DEFECT
:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description kely_garcia 2007-06-29 01:00:27 UTC
Build ID: Netbeans 6.0 M9 (070502)

Steps To Reproduce:
Push down method m on the following returns an erroneous message: "Cannot push down any members. The selected type has 
no subtypes". It should be possible to push down method m in this case. 

public class A {  
  public void m(){
  }
}
class B extends A {
  void mPrime(){
    new A().m();
  }
}
Comment 1 Jan Becicka 2007-06-29 11:11:21 UTC

*** This issue has been marked as a duplicate of 108482 ***
Comment 2 kely_garcia 2007-08-09 21:49:05 UTC
If we Push down method A.m() in the following program, we get this compilation error: "cannot find symbol: method m
()". I think this bug is different from 108482. 

A.java
package p;

public class A {  
  public void m(){
  }
}

B.java
package p;

class B extends A {
  void mPrime(){
    new A().m();
  }
}


By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo