WIP: replaced diff to diff-match-patch (#3675) #3989
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description of the Change
I checked the #3675 issue and changed the existing diff library to Google's diff-patch-match.
Benefits
Test Code (copy from issue)
Before change: About 2 minutes 1 second
After change: About 1 second
Applicable issues
Diff-patch-match is character-based, unlike diff.
So it is written to be processed line by line using line-mode.
However, the result screen is different because there is a difference from Patch Process.
Test Code
Comparison of Patch Results
Before
After
Comparison of Excution Results
Before
After
RESULT
So I don't think it's user friendly.
Would it be better to work on the same output as the existing result? Or would you like to hear other ways to find out?
Please, I want to listen to the comments and advices.
Line mode
That library is character-based