1
1
mirror of https://github.com/github/semantic.git synced 2024-12-26 08:25:19 +03:00
Commit Graph

6312 Commits

Author SHA1 Message Date
Rob Rix
13a90624de Stub in a quick Arbitrary instance for Child. 2016-05-20 15:34:20 -04:00
Rob Rix
72455cdecd Add a datatype to represent children for alignBranch property tests. 2016-05-20 15:34:11 -04:00
Rob Rix
5355143395 Add some pending properties. 2016-05-20 13:05:38 -04:00
Rob Rix
018f289fb5 Abstract PrettyDiff over a type parameter. 2016-05-20 12:39:56 -04:00
Rob Rix
a2952307f6 Produce a single element with the rest of the lines in a split-up child. 2016-05-20 11:09:15 -04:00
Rob Rix
d99e4ab39b When we only have ranges on one side, default the other to assume intersecting. 2016-05-19 16:51:33 -04:00
Rob Rix
cb2ffd188c Add a test case of ungreedy asymmetrical node alignment. 2016-05-19 16:16:35 -04:00
Rob Rix
f1d9cc3f2f Skip past nonintersecting children.
This resolves failures in two distinct cases where changing the default
for handling asymmetrical ranges had opposite outcomes.
2016-05-19 16:16:15 -04:00
Rob Rix
2fa8060a1c Revert "Default the intersection assumption to True."
This reverts commit 9bf8bb93f3ddf06027e9aafd7b7062b398c5409f.
2016-05-19 16:13:43 -04:00
Rob Rix
16b1d5b4f3 Handle the empty child case with otherwise. 2016-05-19 16:12:51 -04:00
Rob Rix
0fd78af15e 🔥 the properties, since we’ve captured them. 2016-05-19 15:12:24 -04:00
Rob Rix
2df52eec1d Ditto for the json output. 2016-05-19 14:04:16 -04:00
Rob Rix
172a0aaa47 We no longer extend an expression statement over the end of the line, apparently. 2016-05-19 14:00:22 -04:00
Rob Rix
1d2ec4c5f0 The expected alignment of this case has changed. 2016-05-19 13:54:29 -04:00
Rob Rix
c839a434e8 🔥 distribute. 2016-05-19 13:43:02 -04:00
Rob Rix
bf656592c1 🔥 pairRangesWithLine. 2016-05-19 13:42:58 -04:00
Rob Rix
f4923c63b7 🔥 spanAndSplitFirstLines. 2016-05-19 13:42:53 -04:00
Rob Rix
73746013fb 🔥 alignChildrenInRanges. 2016-05-19 13:42:46 -04:00
Rob Rix
20627f764f Test alignBranch instead of alignChildrenInRanges. 2016-05-19 13:40:10 -04:00
Rob Rix
572082cacd Diff Keyed nodes using alignBranch. 2016-05-19 13:38:24 -04:00
Rob Rix
527e87fc4b Merge branch 'master' into cofree-and-bifunctors-sitting-in-a-tree-a-l-i-g-n-edly 2016-05-19 13:36:57 -04:00
Rob Rix
64ac903f3f Align branches within a copointed context. 2016-05-19 13:26:36 -04:00
Rob Rix
ac17a13167 Test that context-only lines are paired up before the asymmetrical halves of split-up symmetrical children. 2016-05-19 12:52:51 -04:00
Rob Rix
17d2e8fe62 Default the intersection assumption to True.
This fixes an issue where we dropped asymmetrical children on the
opposite side from earlier asymmetrical children when splitting up
deletions/insertions.
2016-05-19 12:39:43 -04:00
Rob Rix
d25f7ddc7f Test that we align deletions on a line before insertions. 2016-05-19 12:22:48 -04:00
Rob Rix
1979f4e32f Make it convenient to show the raw structures for strange failure cases. 2016-05-19 12:22:33 -04:00
Rob Rix
80f58f01e3 Do some gymnastics to allow our DSL to construct terms/diffs uniformly. 2016-05-19 12:12:11 -04:00
Rob Rix
198304d45d Use the insert/delete constructors in the test fixtures. 2016-05-19 11:10:48 -04:00
Rob Rix
7bc9a358a5 Add PatchConstructible instances to Patch/SplitPatch. 2016-05-19 11:04:19 -04:00
Rob Rix
04ef584b6c Add a typeclass to make patches/split patches. 2016-05-19 11:03:45 -04:00
Rob Rix
3e63b464f7 Test that symmetrical nodes are split if forced by earlier symmetrical nodes. 2016-05-19 09:01:15 -04:00
Rob Rix
4f13339838 🔥 some redundant bits of the comments. 2016-05-19 00:23:04 -04:00
Rob Rix
c50493175b Remove the redundant tests of asymmetrical nodes preceding/following symmetrical ones. 2016-05-19 00:21:41 -04:00
Rob Rix
24f98f7db9 Test that symmetrical nodes force alignment on both sides. 2016-05-19 00:19:08 -04:00
Rob Rix
17403fc2b2 Fix up the test of symmetrical nodes and following asymmetrical ones. 2016-05-19 00:18:49 -04:00
Rob Rix
b86ce458b0 Test that symmetrical nodes force alignment of later asymmetrical nodes on the same line. 2016-05-19 00:15:03 -04:00
Rob Rix
7d591e737f Test that symmetrical nodes force alignment of earlier asymmetrical nodes on the same line. 2016-05-19 00:13:49 -04:00
Rob Rix
5c2d9b6b01 Change a test name. 2016-05-19 00:13:26 -04:00
Rob Rix
264f1cf5bd Merge branch 'master' into cofree-and-bifunctors-sitting-in-a-tree-a-l-i-g-n-edly 2016-05-18 18:21:40 -04:00
Rob Rix
dc8d0d4fdf Add punctuation characters to a test case to clarify the failure. 2016-05-18 17:22:16 -04:00
Rob Rix
99d0496d72 Use first/second to advance asymmetrically before symmetrical children. 2016-05-18 17:22:02 -04:00
Rob Rix
78323c8183 Swap the order of the arguments to alignChildren. 2016-05-18 16:19:40 -04:00
Rob Rix
59ca7fd08b Fix a missing bracket in a comment.
This was making bracket-matcher sad.
2016-05-18 16:15:44 -04:00
Rob Rix
a92f55a053 alignChildren returns the remaining children in the nonintersecting case. 2016-05-18 16:06:15 -04:00
Rob Rix
bb38c87015 Reformat alignChildren’s cases. 2016-05-18 16:03:37 -04:00
Rob Rix
a5960a164f Factor the recursive call of alignChildren into its where clause. 2016-05-18 16:02:38 -04:00
Rob Rix
59ff6fcccd Handle an oxymoronic case to silence a warning (and in hope of future refactoring). 2016-05-18 15:57:32 -04:00
Rob Rix
6ce445068c Move the symmetrical child test up a level.
This avoids redundancy with the does-anything-intersect-on-both-sides
case.
2016-05-18 15:51:49 -04:00
Rob Rix
5e1d111cac Move the asymmetrical computation break into the where clause. 2016-05-18 15:44:04 -04:00
Rob Rix
43a893e843 lineAndRemainingWhere doesn’t imply any. 2016-05-18 15:37:28 -04:00