You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by rh...@apache.org on 2012/08/31 14:04:24 UTC

svn commit: r1379426 - in /subversion/trunk/subversion: bindings/javahl/src/org/apache/subversion/javahl/ConflictDescriptor.java include/svn_wc.h libsvn_wc/conflicts.c libsvn_wc/tree_conflicts.c libsvn_wc/update_editor.c svn/tree-conflicts.c

Author: rhuijben
Date: Fri Aug 31 12:04:23 2012
New Revision: 1379426

URL: http://svn.apache.org/viewvc?rev=1379426&view=rev
Log:
Remove the new in 1.8, but now unused tree conflict reason
'moved-away-and-edited'.

The moved-away status is just a cleaner way of reporting that the
node is deleted and at the same time the root moved. (Which could
also apply to a replaced node). The combination with edited applies
only to a slight subset of the cases and should really be reported
on the to-location of the move.

* subversion/bindings/javahl/src/org/apache/subversion/javahl/ConflictDescriptor.java
  (Reason): Sync with svn_wc.h.

* subversion/include/svn_wc.h
  (svn_wc_conflict_reason_t): Remove reason.

* subversion/libsvn_wc/conflicts.c
  (local_change_map): Remove mapping of reason.

* subversion/libsvn_wc/tree_conflicts.c
  (svn_wc__conflict_reason_map): Remove mapping of reason.

* subversion/libsvn_wc/update_editor.c
  (check_tree_conflict,
   delete_entry,
   open_directory,
   open_file): Remove check for unused tree conflict reason.

* subversion/svn/tree-conflicts.c
  (map_conflict_reason_human,
   map_conflict_reason_xml): Remove mapping of reason.

Modified:
    subversion/trunk/subversion/bindings/javahl/src/org/apache/subversion/javahl/ConflictDescriptor.java
    subversion/trunk/subversion/include/svn_wc.h
    subversion/trunk/subversion/libsvn_wc/conflicts.c
    subversion/trunk/subversion/libsvn_wc/tree_conflicts.c
    subversion/trunk/subversion/libsvn_wc/update_editor.c
    subversion/trunk/subversion/svn/tree-conflicts.c

Modified: subversion/trunk/subversion/bindings/javahl/src/org/apache/subversion/javahl/ConflictDescriptor.java
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/bindings/javahl/src/org/apache/subversion/javahl/ConflictDescriptor.java?rev=1379426&r1=1379425&r2=1379426&view=diff
==============================================================================
--- subversion/trunk/subversion/bindings/javahl/src/org/apache/subversion/javahl/ConflictDescriptor.java (original)
+++ subversion/trunk/subversion/bindings/javahl/src/org/apache/subversion/javahl/ConflictDescriptor.java Fri Aug 31 12:04:23 2012
@@ -250,7 +250,19 @@ public class ConflictDescriptor
         /**
          * Object is already replaced.
          */
-        replaced;
+        replaced,
+
+        /**
+         * Object is moved away.
+         * @since 1.8
+         */
+        moved_away,
+
+        /**
+         * Object is moved here.
+         * @since 1.8
+         */
+        moved_here;
     }
 
     public enum Operation

Modified: subversion/trunk/subversion/include/svn_wc.h
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/include/svn_wc.h?rev=1379426&r1=1379425&r2=1379426&view=diff
==============================================================================
--- subversion/trunk/subversion/include/svn_wc.h (original)
+++ subversion/trunk/subversion/include/svn_wc.h Fri Aug 31 12:04:23 2012
@@ -1593,10 +1593,6 @@ typedef enum svn_wc_conflict_reason_t
   svn_wc_conflict_reason_replaced,
   /** Object is moved away. @since New in 1.8. */
   svn_wc_conflict_reason_moved_away,
-  /** Object is moved away and was edited post-move. @since New in 1.8. */
-  /* ### Do we really need this. The edit state is on a different node,
-         which might just change while the tree conflict exists? */
-  svn_wc_conflict_reason_moved_away_and_edited,
   /** Object is moved here. @since New in 1.8. */
   svn_wc_conflict_reason_moved_here
 

Modified: subversion/trunk/subversion/libsvn_wc/conflicts.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/conflicts.c?rev=1379426&r1=1379425&r2=1379426&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/conflicts.c (original)
+++ subversion/trunk/subversion/libsvn_wc/conflicts.c Fri Aug 31 12:04:23 2012
@@ -511,9 +511,6 @@ static const svn_token_map_t local_chang
   { "replaced",         svn_wc_conflict_reason_replaced },
   { "moved-away",       svn_wc_conflict_reason_moved_away },
   { "moved-here",       svn_wc_conflict_reason_moved_here },
-  /* ### Do we really need this. The edit state is on a different node,
-         which might just change while the tree conflict exists? */
-  { "moved-and-edited", svn_wc_conflict_reason_moved_away_and_edited },
   { NULL }
 };
 

Modified: subversion/trunk/subversion/libsvn_wc/tree_conflicts.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/tree_conflicts.c?rev=1379426&r1=1379425&r2=1379426&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/tree_conflicts.c (original)
+++ subversion/trunk/subversion/libsvn_wc/tree_conflicts.c Fri Aug 31 12:04:23 2012
@@ -78,7 +78,6 @@ const svn_token_map_t svn_wc__conflict_r
   { "replaced",    svn_wc_conflict_reason_replaced },
   { "unversioned", svn_wc_conflict_reason_unversioned },
   { "moved-away", svn_wc_conflict_reason_moved_away },
-  { "moved-away-and-edited", svn_wc_conflict_reason_moved_away_and_edited },
   { "moved-here", svn_wc_conflict_reason_moved_here },
   { NULL }
 };

Modified: subversion/trunk/subversion/libsvn_wc/update_editor.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/update_editor.c?rev=1379426&r1=1379425&r2=1379426&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/update_editor.c (original)
+++ subversion/trunk/subversion/libsvn_wc/update_editor.c Fri Aug 31 12:04:23 2012
@@ -1474,7 +1474,6 @@ check_tree_conflict(svn_skel_t **pconfli
   if (reason == svn_wc_conflict_reason_edited
       || reason == svn_wc_conflict_reason_deleted
       || reason == svn_wc_conflict_reason_moved_away
-      || reason == svn_wc_conflict_reason_moved_away_and_edited
       || reason == svn_wc_conflict_reason_replaced)
     /* When the node existed before (it was locally deleted, replaced or
      * edited), then 'update' cannot add it "again". So it can only send
@@ -1730,7 +1729,6 @@ delete_entry(const char *path,
         }
       else if (reason == svn_wc_conflict_reason_deleted
                || reason == svn_wc_conflict_reason_moved_away
-               || reason == svn_wc_conflict_reason_moved_away_and_edited
                || reason == svn_wc_conflict_reason_replaced)
         {
           /* The item does not exist locally because it was already shadowed.
@@ -2264,7 +2262,6 @@ open_directory(const char *path,
                                                   db->pool, db->pool));
       SVN_ERR_ASSERT(reason == svn_wc_conflict_reason_deleted
                      || reason == svn_wc_conflict_reason_moved_away
-                     || reason == svn_wc_conflict_reason_moved_away_and_edited
                      || reason == svn_wc_conflict_reason_replaced);
 
       /* Continue updating BASE */
@@ -3309,7 +3306,6 @@ open_file(const char *path,
                                                   fb->pool, fb->pool));
       SVN_ERR_ASSERT(reason == svn_wc_conflict_reason_deleted
                      || reason == svn_wc_conflict_reason_moved_away
-                     || reason == svn_wc_conflict_reason_moved_away_and_edited
                      || reason == svn_wc_conflict_reason_replaced);
 
       /* Continue updating BASE */

Modified: subversion/trunk/subversion/svn/tree-conflicts.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/svn/tree-conflicts.c?rev=1379426&r1=1379425&r2=1379426&view=diff
==============================================================================
--- subversion/trunk/subversion/svn/tree-conflicts.c (original)
+++ subversion/trunk/subversion/svn/tree-conflicts.c Fri Aug 31 12:04:23 2012
@@ -63,7 +63,6 @@ static const svn_token_map_t map_conflic
   { N_("replace"),      svn_wc_conflict_reason_replaced },
   { N_("unversioned"),  svn_wc_conflict_reason_unversioned },
   { N_("moved away"),   svn_wc_conflict_reason_moved_away },
-  { N_("moved away and edited"), svn_wc_conflict_reason_moved_away_and_edited },
   { N_("moved here"),   svn_wc_conflict_reason_moved_here },
   { NULL,               0 }
 };
@@ -79,7 +78,6 @@ static const svn_token_map_t map_conflic
   { "replace",          svn_wc_conflict_reason_replaced },
   { "unversioned",      svn_wc_conflict_reason_unversioned },
   { "moved-away",       svn_wc_conflict_reason_moved_away },
-  { "moved-away-and-edited", svn_wc_conflict_reason_moved_away_and_edited },
   { "moved-here",       svn_wc_conflict_reason_moved_here },
   { NULL,               0 }
 };



Re: svn commit: r1379426 - in /subversion/trunk/subversion: bindings/javahl/src/org/apache/subversion/javahl/ConflictDescriptor.java include/svn_wc.h libsvn_wc/conflicts.c libsvn_wc/tree_conflicts.c libsvn_wc/update_editor.c svn/tree-conflicts.c

Posted by Stefan Sperling <st...@apache.org>.
On Fri, Aug 31, 2012 at 12:04:24PM -0000, rhuijben@apache.org wrote:
> Author: rhuijben
> Date: Fri Aug 31 12:04:23 2012
> New Revision: 1379426
> 
> URL: http://svn.apache.org/viewvc?rev=1379426&view=rev
> Log:
> Remove the new in 1.8, but now unused tree conflict reason
> 'moved-away-and-edited'.
> 
> The moved-away status is just a cleaner way of reporting that the
> node is deleted and at the same time the root moved. (Which could
> also apply to a replaced node). The combination with edited applies
> only to a slight subset of the cases and should really be reported
> on the to-location of the move.
> 

Thanks for taking care of this, Bert. I had been planning to remove
this conflict reason, too. I introduced it to allow the update editor
to label this particular case in a special way.
But with the new design of handling this at 'svn resolve' time we don't
need this special conflict reason anymore. The resolver can compare file
contents at run time to determine whether the file was also edited
before or after being moved.