User Tools

Site Tools


projects:proof

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
projects:proof [2021/11/05 16:04] โ€“ Owen Mellemaprojects:proof [2021/11/08 22:00] (current) โ€“ Owen Mellema
Line 51: Line 51:
 The DiffTree Populator takes a Linked AST Pair and constructs a DiffTree based on how nodes are matched. For example, here's a DiffTree constructed from the previous Linked AST Pair. The DiffTree Populator takes a Linked AST Pair and constructs a DiffTree based on how nodes are matched. For example, here's a DiffTree constructed from the previous Linked AST Pair.
  
-{{ :projects:difftree.png?600 |}}+{{:projects:difftree_fixed.png?600}}
  
 Although the algorithim is fairly complex (it took over a month to iron out all the kinks and determine the correct behavior for all cases), the relationship between the Linked AST Pair and the DiffTree can be summarized like this Although the algorithim is fairly complex (it took over a month to iron out all the kinks and determine the correct behavior for all cases), the relationship between the Linked AST Pair and the DiffTree can be summarized like this
Line 61: Line 61:
  
 Using this simple set of rules, we start from the top of the tree and proceed in level order. As you might expect, the ability for nodes to move complicates the algorithm significantly, both in terms of implementation and expected output ๐Ÿ˜. (The test suite used for testing the algorithm contains 53 tests, and is over 2600 lines in length.) Using this simple set of rules, we start from the top of the tree and proceed in level order. As you might expect, the ability for nodes to move complicates the algorithm significantly, both in terms of implementation and expected output ๐Ÿ˜. (The test suite used for testing the algorithm contains 53 tests, and is over 2600 lines in length.)
 +
 +==== Unparser and Semantic Diff ====
 +The Unparser's job is to take a DiffTree, and return something resembling code, albeit with a bit more structure than code. Since this is the opposite job of the Parser, I thought it was fitting to call it an "unparser".
 +
 +{{ :projects:unparsing_version_1.png?600 |}}
projects/proof.1636128263.txt.gz ยท Last modified: 2021/11/05 16:04 by Owen Mellema