title: "Rename in file" error in Eclipse.
body: <p>I have the following code</p>
  
  <pre><code>Data currentNode = treeList.get(i);
  Collections.sort(currentNode.childrenList, new Comparator&lt;Data&gt;() {
      @Override
      public int compare(final Data object1, final Data object2) {
          return object1.getNodeName().compareTo(object2.getNodeName());
      }
     } 
  );
  </code></pre>
  
  <p>But <code>.sort</code> is underlined in red and Eclipse is suggesting <code>Rename in file</code>.</p>
  
  <p>What does this ambiguous error mean?</p>
  
  <p>Note if I do:
  <code>Collections.sort(treeList...</code> instead of <code>Collections.sort(currentNode.childrenList...</code>
  the error disappears even though <code>treeList</code> and <code>childrenList</code> are virtually the same. </p>