1
1
mirror of https://github.com/github/semantic.git synced 2024-12-27 08:54:14 +03:00
Commit Graph

229 Commits

Author SHA1 Message Date
Rob Rix
1b487b6907 🔥 offsetting in toTermName.
toTermName is a shallow traversal, so there’s little or no point in offsetting before recursive calls.
2017-05-08 11:18:23 -04:00
Rob Rix
2e98b4570d Contextualize summaries in diffToTOCSummaries directly. 2017-05-08 11:16:37 -04:00
Rob Rix
9df2a73e38 Tighten up toTermName. 2017-05-08 11:16:23 -04:00
Rob Rix
76002f08c0 🔥 redundant parens. 2017-05-08 09:56:11 -04:00
Rob Rix
f3cf3cb1d1 🔥 SummarizableTerm. 2017-05-08 09:55:56 -04:00
Rob Rix
8d8fa78b47 Simplify summarizable. 2017-05-05 16:34:16 -04:00
Rob Rix
0c7af370f7 Define termToDiffInfo as a paramorphism. 2017-05-05 16:28:46 -04:00
Rob Rix
c73a79eb83 No need to qualify sourceSpan. 2017-05-05 16:19:49 -04:00
Rob Rix
a55b97b017 Use the named field accessor. 2017-05-05 16:08:51 -04:00
Rob Rix
2491dde0f9 Don’t bind the individual info functions. 2017-05-05 16:00:52 -04:00
Rob Rix
e667657d94 Bind the diff info functions at the top level. 2017-05-05 16:00:10 -04:00
Rob Rix
b6cc1cfac1 🔥 redundant parens. 2017-05-05 15:56:15 -04:00
Rob Rix
628bf46ed3 Don’t bind syntax. 2017-05-05 15:56:04 -04:00
Rob Rix
274095720b Tighten up diffToTOCSummaries. 2017-05-05 15:54:38 -04:00
Rob Rix
f820af4f5a Factor the application of toLeafInfos out. 2017-05-05 15:48:54 -04:00
Rob Rix
c3f510f83d Rename toLeafInfos' to toLeafInfos. 2017-05-05 15:45:51 -04:00
Rob Rix
c6b49cba94 Simplify the termToDiffInfo definition by closing over the source. 2017-05-05 15:44:37 -04:00
Rob Rix
0ab53b002a Flatten toTOCSummaries. 2017-05-05 15:33:16 -04:00
Rob Rix
8cd74f6ea2 afterOrBefore always returns a value. 2017-05-05 15:26:26 -04:00
Rob Rix
fbb899250a Replace the summaries maps with Summaries. 2017-04-03 17:15:58 -04:00
Rob Rix
4c24cdf1ad 🔥 TOC’s dependency on Renderer. 2017-03-31 16:48:06 -04:00
Rob Rix
f52894d2e8 Rename DefaultFields to HasDefaultFields. 2017-03-31 15:18:27 -04:00
joshvera
81e178fc61 Keep track of clauses before a Method identifier 2017-03-30 18:00:13 -04:00
joshvera
b5f9938279 Remove ty from Method and throw every part of a call signature into a list 2017-03-29 16:24:54 -04:00
joshvera
cdbd260b0f Remove type from Function and unpack call signatures 2017-03-29 12:36:05 -04:00
Rob Rix
a8410e8829 🔥 various uses of LambdaCase. 2017-03-28 15:32:45 -04:00
Timothy Clem
0cf38c583c Assert to summary json output 2017-02-22 20:05:48 -08:00
Timothy Clem
9910f8dd16 Add friendly category name now that we have singleton methods 2017-02-17 14:57:29 -08:00
Josh Vera
696e4f6a8c Merge branch 'master' into ruby-singleton-methods 2017-02-17 15:02:32 -05:00
Josh Vera
d0af7a2f40 Merge branch 'master' into it-slices,-it-dices 2017-02-17 14:52:42 -05:00
Timothy Clem
a10bc515c0 ++tree-sitter-ruby and parse singleton methods to fix ambiguity 2017-02-17 11:34:47 -08:00
Rob Rix
a7bfbb72f4 Rename characterRange to byteRange. 2017-02-16 11:58:26 -05:00
Timothy Clem
70c8e2a57b Property test that toc summarizes methods and functions 2017-02-15 16:13:34 -08:00
Timothy Clem
b34c71dcc5 Merge branch 'master' into dedupe-added-removed-methods 2017-02-15 08:14:21 -08:00
Timothy Clem
09337e21d8 Merge remote-tracking branch 'origin/master' into go-receiver-toc-iteration 2017-02-14 13:13:11 -08:00
Timothy Clem
1facca0b50 Add failing toc summary test and refactor removeDupes 2017-02-14 11:29:24 -08:00
Timothy Clem
8bc4da76c9 Have to check parentInfo for duplicates 2017-02-14 08:27:00 -08:00
Timothy Clem
2770540191 Make sure we have a real Summarizable to replace with 2017-02-13 17:30:33 -08:00
Timothy Clem
d68633f643 WIP - identify similar methods/functions 2017-02-13 17:18:25 -08:00
Timothy Clem
31519dda42 Remove dups, including matching method names 2017-02-13 16:15:38 -08:00
Timothy Clem
cb611a4aa6 Pass in parentOffset to toTermName 2017-02-13 12:53:20 -08:00
Rob Rix
52025ac5e5 Don’t trim the source for recursive calls into termToDiffInfo. 2017-02-13 15:19:06 -05:00
Rob Rix
00c14e403a Revert "Source carries its Range."
This reverts commit 6e075787935c10b0bd7256673a5623cb5d1a4945.
2017-02-10 16:44:09 -05:00
Rob Rix
672ff179ed Source carries its Range. 2017-02-10 15:33:41 -05:00
Rob Rix
2a30f6d462 Pre-slice in termToDiffInfo. 2017-02-10 14:23:42 -05:00
Rob Rix
5134595525 Rename blob to source. 2017-02-10 14:18:55 -05:00
Rob Rix
bc2a29d84e Source is no longer parametric in the character type. 2017-02-10 11:21:24 -05:00
Rob Rix
35c39e8b56 Change subtractRange to offsetRange.
This has slightly clearer semantics.
2017-02-10 11:11:25 -05:00
Timothy Clem
7ba739a508 Properly calculate range for subterms 2017-02-09 14:47:35 -08:00
Rob Rix
ac4df9a7b3 Remove the Foldable instance for Source. 2017-02-09 17:10:16 -05:00
Rob Rix
fe22126059 Pre-slice the source. 2017-02-09 16:33:33 -05:00
Timothy Clem
a3a895d107 Another iterator for go method toc summaries 2017-02-08 10:57:13 -08:00
Timothy Clem
ded960356a Remove S.MemberAccess case entirely since it's now handled above 2017-02-07 15:20:27 -08:00
Timothy Clem
2f230a485e Add receiver to Syntax.Method 2017-02-07 14:53:15 -08:00
Timothy Clem
85afbd6df4 Handle termAssignment for Ruby singleton method defs 2017-02-07 11:59:18 -08:00
joshvera
0503fc9555 Flatten BranchInfo patches 2017-01-26 15:07:18 -05:00
joshvera
386fa47ae6 s/Error/ParseError 2017-01-26 12:48:03 -05:00
joshvera
69cf915bf7 Only export toc 2017-01-26 12:46:28 -05:00
joshvera
3ab42ca794 add a param 2017-01-25 18:26:03 -05:00
Timothy Clem
3d4f6fe48b Remove need to qualify patch 2017-01-25 10:45:56 -08:00
Timothy Clem
a8fed91deb No need for HideInfo constructor b/c we only surface functions/methods 2017-01-25 08:47:50 -08:00
Timothy Clem
2b0363e031 Remove comments and API sketching 2017-01-25 08:46:45 -08:00
joshvera
dd6a5d3a20 Rename sourceSpan keys to span 2017-01-24 17:20:22 -05:00
joshvera
348d5ae699 Move patchType to Patch 2017-01-24 16:00:25 -05:00
joshvera
e3da60eada Add afterOrBefore function to Patch.hs 2017-01-24 15:58:17 -05:00
Timothy Clem
e53ae6a88a Catch (and hide) NotSummarizable leaves 2017-01-24 11:25:44 -08:00
Timothy Clem
f49fc1910d Don't print method arguments 2017-01-24 11:18:59 -08:00
Timothy Clem
9ec2262b38 Refactor names and handling of what's summarizable 2017-01-24 11:16:22 -08:00
joshvera
3f34bcec46 Expand toTermName to summarize methods and functions 2017-01-24 12:14:14 -05:00
joshvera
acb277e32c remove duplicates 2017-01-24 12:13:59 -05:00
joshvera
1fe58a5c48 Panic in toJSON if we see a None 2017-01-24 12:13:22 -05:00
joshvera
b3bbff3f45 Output term, category, sourceSpan 2017-01-23 17:46:29 -05:00
joshvera
c35d7e8089 Summarize functions and methods to ExpressionInfo 2017-01-23 17:26:43 -05:00
joshvera
3177a565a7 Append parent annotations to summaries 2017-01-23 16:59:47 -05:00
joshvera
cc4cc5efc6 Add ParentInfo to carry information about parent or expression information 2017-01-23 16:33:07 -05:00
joshvera
261f374fb5 Parameterize JSONSummary with term context info types 2017-01-23 15:58:20 -05:00
Timothy Clem
381549c045 Structure to produce toc summaries 2017-01-23 11:13:11 -08:00
joshvera
f8ecbf9286 WIP stub TOC renderer 2017-01-23 12:16:59 -05:00
joshvera
18c8a0124d Add a stub TOC renderer 2017-01-23 11:22:51 -05:00