algesten / jsondiff

Structural JSON diff/patch tool.
Other
66 stars 27 forks source link

Intuitive instruction order #4

Closed algesten closed 12 years ago

algesten commented 12 years ago

It could be argued that the following order is "more intuitive" since set/merge operations would have indexes that are true for the original array being modified.

  1. Merge
  2. Set
  3. Insert
  4. Delete

This way only the last delete instructions may be affected by previous inserts. The current way all instructions are affected since deletions are done first.

algesten commented 12 years ago

Attempt to sort this in d452e81cf8451cf9a2fbb6fad00c1c5da62e3658