corinthia-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jan i <j...@apache.org>
Subject Re: html ids
Date Sun, 21 Jun 2015 12:06:37 GMT
I too would like to get rid of the ids, but I took a good look at the
algorithm and I do not think it can easily be adapted.

the algorithm seems to work on sequences, which might work with a uniform
tree structure, but our tree structure is just about as nasty as it gets
a tree type (branch as instance) can be anywhere in the tree and even be
present within the branch itself.

Our problem is a lot more similar to the math graph theory. I remember APL
(whoever knows that today) had some functions to compare and work on that,
I
will search my old library (meaning physical paper).

rgds
jan i.


On 19 June 2015 at 18:28, Peter Kelly <pmkelly@apache.org> wrote:

> > On 19 Jun 2015, at 11:20 pm, Peter Kelly <pmkelly@apache.org> wrote:
>
> > I experimented with this a while back using the Myers diff algorithm
>
> > [1] http://www.xmailserver.org/diff2.pdf
>
> This is a fascinating algorithm BTW, and one of my favourites of all time,
> because of the way in which it re-casts the problem (diffing two files)
> into a totally different form (finding the shortest path through a graph),
> and explains the solution in terms of this latter form. The paper is pretty
> heavy reading, but there’s a good implementation here:
>
>
> http://www.codeproject.com/Articles/42279/Investigating-Myers-diff-algorithm-Part-of
>
> There’s an implementation of this in Editor/src/util.js (function diff).
> It’s not actually used anywhere any I can’t remember why I added it there,
> but useful nonetheless as as starting point if you’re looking for an
> implementation.
>
> —
> Dr Peter M. Kelly
> pmkelly@apache.org
>
> PGP key: http://www.kellypmk.net/pgp-key <http://www.kellypmk.net/pgp-key>
> (fingerprint 5435 6718 59F0 DD1F BFA0 5E46 2523 BAA1 44AE 2966)
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message