...ut having to do multiple passes on the entire file.
This adds support for applying overlapping patches to the same AST wi…
…thout having to do multiple passes on the entire file.
I'm nervous about the performance trade-off this has, but it's a good change for now. Also, really need test coverage on the jspatch code :-X
Unfortunately it's currently the only way to make a pass of jspatch consistent - without this there's no guarantee that every patch in the patchfile will be applied to the source.
Of course, the optimal solution would be to only properly keep track of the modified segments so at to allow overlapping change sets.
Alternatively a separate mode where the AST is modified freely and then compiled back in to js.
Oh, and of course this change means that jspatch might not terminate (without crashing) :)
Either of the proposed solutions is better. We can deal with it later.