@@ -108,7 +108,8 @@ pub mod commit {
108108pub mod tree {
109109 use gix_merge:: blob:: builtin_driver;
110110 pub use gix_merge:: tree:: {
111- treat_as_unresolved, Conflict , ContentMerge , Resolution , ResolutionFailure , TreatAsUnresolved ,
111+ apply_index_entries, treat_as_unresolved, Conflict , ContentMerge , Resolution , ResolutionFailure ,
112+ TreatAsUnresolved ,
112113 } ;
113114
114115 /// The outcome produced by [`Repository::merge_trees()`](crate::Repository::merge_trees()).
@@ -138,22 +139,19 @@ pub mod tree {
138139
139140 /// Returns `true` if `index` changed as we applied conflicting stages to it, using `how` to determine if a
140141 /// conflict should be considered unresolved.
141- /// It's important that `index` is at the state of [`Self::tree`].
142- ///
143- /// Note that in practice, whenever there is a single [conflict](Conflict), this function will return `true`.
144142 ///
145- /// ### Important
143+ /// `removal_mode` decides how unconflicted entries should be removed if they are superseded by
144+ /// their conflicted counterparts.
146145 ///
147- /// Also, the unconflicted stage of such entries will be removed merely by setting a flag, so the
148- /// in-memory entry is still present.
149- /// One can prune `index` [in-memory](gix_index::State::remove_entries()) or write it to disk, which will
150- /// cause entries marked for removal not to be persisted.
146+ /// It's important that `index` is at the state of [`Self::tree`].
147+ /// Note that in practice, whenever there is a single [conflict](Conflict), this function will return `true`.
151148 pub fn index_changed_after_applying_conflicts (
152149 & self ,
153150 index : & mut gix_index:: State ,
154151 how : TreatAsUnresolved ,
152+ removal_mode : apply_index_entries:: RemovalMode ,
155153 ) -> bool {
156- gix_merge :: tree :: apply_index_entries ( & self . conflicts , how, index)
154+ apply_index_entries ( & self . conflicts , how, index, removal_mode )
157155 }
158156 }
159157
0 commit comments