Index: OsmPrimitive.java
===================================================================
--- OsmPrimitive.java	(revision 1566)
+++ OsmPrimitive.java	(working copy)
@@ -284,20 +284,37 @@
     }
 
     /**
-     * Perform an equality compare for all non-volatile fields not only for the id
-     * but for the whole object (for conflict resolving)
-     * @param semanticOnly if <code>true</code>, modified flag and timestamp are not compared
+     * Compare this OSM primitive with <code>other</code>. Can be invoked in one of two modes:
+     * <ul>
+     *   <li>to compare the values of "semantic" fields only. Replies true, if the fields id, incomplete, deleted and
+     *      the set of key/value-pairs are equal</li>
+     *   <li>to compare the values of <em>all</em> fields. Replies true, if the "semantic" fields
+     *     and in addition the fields modified, timestamp, version, visible and user are equal. 
+     * </ul>
+     * 
+     * @param semanticOnly if <code>true</code>,compares "semantic" fields only; if <code>false</code>, compares
+     *    all fields
+     *    
+     * @return true, if this and <code>other</code> are equal; false, otherwise 
      */
-    public boolean realEqual(OsmPrimitive osm, boolean semanticOnly) {
-        return id == osm.id
-        && incomplete == osm.incomplete
-        && deleted == osm.deleted
-        && (semanticOnly || (modified == osm.modified
-         && timestamp == osm.timestamp
-         && version == osm.version
-         && visible == osm.visible
-         && (user == null ? osm.user==null : user==osm.user)))
-        && (keys == null ? osm.keys==null : keys.equals(osm.keys));
+    public boolean realEqual(OsmPrimitive other, boolean semanticOnly) {
+        boolean ret =
+             id == other.id
+          && incomplete == other.incomplete
+          && deleted == other.deleted
+          && (keys == null ? other.keys==null : keys.equals(other.keys));    
+        
+        if (semanticOnly) {
+            return ret;
+        }
+        ret = ret 
+            && modified == other.modified
+            && timestamp == other.timestamp
+            && version == other.version
+            && visible == other.visible
+            && (user == null ? other.user==null : user==other.user)         
+        ;
+        return ret;
     }
 
     /**
