Commit Graph

14 Commits

Author SHA1 Message Date
Alex Hoppen
2193a7b437 [incrParse] Compute NodeStart on the fly when looking up nodes
This is faster than invoking getAbsolutePosition which needs to walk the
tree again.
2018-08-02 14:28:59 -07:00
Alex Hoppen
c8226d1507 [libSyntax] Make a typealias to unsigned to represent SyntaxNodeIds 2018-07-19 13:57:08 -07:00
Alex Hoppen
419ba044f1 [libSyntax] Record reused node IDs
This is cheaper than recording reused region offsets and the reused node
IDs will later be used to incrementally transfer the syntax to
SwiftSyntax.
2018-07-19 13:55:57 -07:00
Alex Hoppen
705f5b79a2 [libSyntax] Rename getAbsolutePosition-related methods for more clarity 2018-07-19 09:15:53 -07:00
Alex Hoppen
b2ebc96510 [incrParse] Reparse a node if the next leaf node has been modified 2018-05-22 09:07:55 -07:00
Alex Hoppen
b26dd1118c [incrParse] Fix swift-syntax-test not complaining about unexpected reparsed functions 2018-05-22 08:52:40 -07:00
Alex Hoppen
ec4a527c44 [incrParse] Reparse nodes if the next node's trailing trivia has changed 2018-05-22 08:52:36 -07:00
Alex Hoppen
8c9e2e07ec [incParse] Make the SytnaxParsingCache operate on the leading trivia's start 2018-05-22 08:52:35 -07:00
Alex Hoppen
8998b27dd4 [incrParse] Add coloured output indicating which code got reused 2018-05-22 08:52:34 -07:00
Alex Hoppen
92f8f34d22 [incrParse] Store reused regions and output them after parsing 2018-05-22 08:52:34 -07:00
Alex Hoppen
65ac4f57a4 [incrParse] Refactor node reusability into separate function 2018-05-22 08:52:34 -07:00
Alex Hoppen
186feb6f0e [incrParse] Allow information about node reused be outputted 2018-05-22 08:52:33 -07:00
Alex Hoppen
60d11d24f8 [incrParse] Reparse a node if the next leaf node has been modified 2018-05-22 08:52:33 -07:00
Alex Hoppen
de9737c946 [incrParse] Support incremental parsing for edited files 2018-05-22 08:52:33 -07:00