Index: trunk/src/org/openstreetmap/josm/data/coor/ILatLon.java
===================================================================
--- trunk/src/org/openstreetmap/josm/data/coor/ILatLon.java	(revision 18458)
+++ trunk/src/org/openstreetmap/josm/data/coor/ILatLon.java	(revision 18464)
@@ -16,4 +16,9 @@
  */
 public interface ILatLon {
+    /**
+     * Minimum difference in location to not be represented as the same position.
+     * The API returns 7 decimals.
+     */
+    double MAX_SERVER_PRECISION = 1e-7;
 
     /**
@@ -52,3 +57,27 @@
         }
     }
+
+    /**
+     * Determines if the other point has almost the same lat/lon values.
+     * @param other other lat/lon
+     * @return <code>true</code> if the other point has almost the same lat/lon
+     * values, only differing by no more than 1 / {@link #MAX_SERVER_PRECISION MAX_SERVER_PRECISION}.
+     * @since 18464 (extracted from {@link LatLon})
+     */
+    default boolean equalsEpsilon(ILatLon other) {
+        return equalsEpsilon(other, MAX_SERVER_PRECISION);
+    }
+
+    /**
+     * Determines if the other point has almost the same lat/lon values.
+     * @param other other lat/lon
+     * @param precision The precision to use
+     * @return <code>true</code> if the other point has almost the same lat/lon
+     * values, only differing by no more than 1 / precision.
+     * @since 18464 (extracted from {@link LatLon})
+     */
+    default boolean equalsEpsilon(ILatLon other, double precision) {
+        double p = precision / 2;
+        return Math.abs(lat() - other.lat()) <= p && Math.abs(lon() - other.lon()) <= p;
+    }
 }
Index: trunk/src/org/openstreetmap/josm/data/coor/LatLon.java
===================================================================
--- trunk/src/org/openstreetmap/josm/data/coor/LatLon.java	(revision 18458)
+++ trunk/src/org/openstreetmap/josm/data/coor/LatLon.java	(revision 18464)
@@ -46,5 +46,5 @@
      * The API returns 7 decimals.
      */
-    public static final double MAX_SERVER_PRECISION = 1e-7;
+    public static final double MAX_SERVER_PRECISION = ILatLon.MAX_SERVER_PRECISION;
     /**
      * The inverse of the server precision
@@ -186,8 +186,9 @@
      * @return <code>true</code> if the other point has almost the same lat/lon
      * values, only differing by no more than 1 / {@link #MAX_SERVER_PRECISION MAX_SERVER_PRECISION}.
-     */
+     * @deprecated since 18464 (use {@link ILatLon#equalsEpsilon(ILatLon)} instead)
+     */
+    @Deprecated
     public boolean equalsEpsilon(LatLon other) {
-        double p = MAX_SERVER_PRECISION / 2;
-        return Math.abs(lat()-other.lat()) <= p && Math.abs(lon()-other.lon()) <= p;
+        return ILatLon.super.equalsEpsilon(other);
     }
 
Index: trunk/src/org/openstreetmap/josm/data/osm/Node.java
===================================================================
--- trunk/src/org/openstreetmap/josm/data/osm/Node.java	(revision 18458)
+++ trunk/src/org/openstreetmap/josm/data/osm/Node.java	(revision 18464)
@@ -293,7 +293,8 @@
 
     private boolean hasEqualCoordinates(Node other) {
-        final LatLon c1 = getCoor();
-        final LatLon c2 = other.getCoor();
-        return (c1 == null && c2 == null) || (c1 != null && c2 != null && c1.equalsEpsilon(c2));
+        if (this.isLatLonKnown() && other.isLatLonKnown()) {
+            return this.equalsEpsilon(other);
+        }
+        return false;
     }
 
Index: trunk/src/org/openstreetmap/josm/data/osm/NodePositionComparator.java
===================================================================
--- trunk/src/org/openstreetmap/josm/data/osm/NodePositionComparator.java	(revision 18458)
+++ trunk/src/org/openstreetmap/josm/data/osm/NodePositionComparator.java	(revision 18464)
@@ -17,5 +17,5 @@
     public int compare(Node n1, Node n2) {
 
-        if (n1.getCoor().equalsEpsilon(n2.getCoor()))
+        if (n1.equalsEpsilon(n2))
             return 0;
 
