Closed Gocy015 closed 5 years ago
I've notice that if i change the code to
let changes =diff(old: originalLines, new: diffLines)
it becomes much faster, diff
uses Heckel
to diff the arrays, but i want to eliminate Move
, how can i achieve that using Heckel
?
btw, it seems that Heckel
uses delete + insert
instead of replace
, which is another feature that i want..
@Gocy015 Hi, we need to tweak the algorithm code a bit to achieve what you want, but the design of the library is to have move changes. Hope you understand.
ok, thx!
Hi, i am trying to implement a text-base diff viewer, my code looks like the following:
my sample files are 2 objc source files with 650+lines, and only 1 line is different , and the log prints out:
DiffVC, diff algorithm cost 6.890240641998389
Any idea of why this is so slow?