Skip to content

Commit

Permalink
Use MyersUkkonenDiff over HuntMcilroyDiff
Browse files Browse the repository at this point in the history
This appears to improve performance for large files.
  • Loading branch information
MariusDoe committed Oct 3, 2024
1 parent ecf42ec commit 51dd528
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ stringMergeLeft: leftString right: rightString base: baseString ifUnchanged: unc
file0: baseString lines;
file1: leftLines;
file2: rightString lines;
diffClass: HuntMcilroyDiff;
diffClass: SquotTextUtilities diffClass;
merge: true.
^ (diffResult size = 1 and: [diffResult first key = #ok])
ifFalse: [conflictBlock value: (SquotMergeConflict left: leftString right: rightString base: baseString)]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"atomicMergeLeft:right:base:ifUnchanged:ifMerged:ifConflict:" : "mad 9/29/2024 16:04",
"hexHashMerge:left:right:base:ifUnchanged:" : "mad 10/2/2024 20:28",
"stringMergeLeft:right:base:ifConflict:" : "mad 10/2/2024 20:57",
"stringMergeLeft:right:base:ifUnchanged:ifMerged:ifConflict:" : "mad 10/2/2024 20:56",
"stringMergeLeft:right:base:ifUnchanged:ifMerged:ifConflict:" : "mad 10/3/2024 18:30",
"stringOrNilMergeLeft:right:base:ifUnchanged:ifMerged:ifConflict:" : "mad 10/2/2024 20:56" },
"instance" : {
} }
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ mergeSourceBase: baseSource left: leftSource right: rightSource
file0: baseSource lines;
file1: leftSource lines;
file2: rightSource lines;
diffClass: HuntMcilroyDiff;
diffClass: SquotTextUtilities diffClass;
merge: true.
^ SquotTextUtilities joinTexts: (Array streamContents: [:stream |
chunks do: [:chunk |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
"left" : "mad 9/7/2023 19:56",
"leftColor" : "mad 9/9/2023 14:54",
"leftSources" : "mad 11/6/2023 15:09",
"mergeSourceBase:left:right:" : "mad 9/12/2023 16:29",
"mergeSourceBase:left:right:" : "mad 10/3/2024 18:30",
"mergeSources" : "mad 11/3/2023 15:38",
"missingSources" : "mad 2/1/2024 16:52",
"preserveUndoWhileReplacing:with:in:" : "mad 9/10/2023 18:36",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
diffing
diffClass
^ HuntMcilroyDiff
^ MyersUkkonenDiff
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"bold:" : "mad 9/27/2023 16:03",
"colorText:with:" : "mad 9/10/2023 18:09",
"diffChunksFrom:to:" : "mad 9/20/2023 13:13",
"diffClass" : "mad 9/8/2023 18:52",
"diffClass" : "mad 10/2/2024 18:29",
"diffFrom:to:" : "mad 9/20/2023 13:05",
"diffFromLines:toLines:" : "mad 9/20/2023 13:05",
"italic:" : "mad 9/10/2023 13:01",
Expand Down

0 comments on commit 51dd528

Please sign in to comment.