Rob Rix
51c0c40814
Dot.
2015-11-17 14:52:41 -08:00
Rob Rix
d34c71ccf1
Move the sources into the package.
2015-11-17 14:49:59 -08:00
Rob Rix
e5b35fdc4a
I mean, sure.
2015-11-17 14:44:16 -08:00
Rob Rix
c0b6b1a4c5
Ignore .stack-work.
2015-11-17 14:44:07 -08:00
Rob Rix
e7de6d3ea2
Construct Cofrees.
2015-11-17 14:32:43 -08:00
Rob Rix
865b38bc2e
Terms are Cofrees.
2015-11-17 14:17:55 -08:00
Rob Rix
9782ce1f62
Ha ha Info is just Info.
2015-11-17 14:17:20 -08:00
Rob Rix
34eb8f9a28
Info has a range and categories.
2015-11-17 14:09:52 -08:00
Rob Rix
6652ef6b3f
Import Cofree.
2015-11-17 14:07:36 -08:00
Rob Rix
87269517dd
Use Data.Fix
instead of Fix
.
2015-11-17 14:06:07 -08:00
Rob Rix
f985212b89
Unpack the Map.
2015-11-17 13:56:40 -08:00
Rob Rix
5b837704ee
Deal with Fixed
.
2015-11-17 13:46:23 -08:00
Rob Rix
fcf1ce0023
Reorder the type parameters ಠ_ಠ
2015-11-17 13:45:14 -08:00
Rob Rix
5e3be122e1
Remove iter
.
2015-11-17 13:44:30 -08:00
Rob Rix
e55712493e
Maps.
2015-11-17 13:44:27 -08:00
Rob Rix
726a31a6cf
Use the correct constructor.
2015-11-17 13:40:19 -08:00
Rob Rix
1a9c5346f3
Spaces.
2015-11-17 13:38:05 -08:00
Rob Rix
a85cbbbd6f
Parenthesize.
2015-11-17 13:37:10 -08:00
Rob Rix
f066ad3844
Import Syntax.
2015-11-17 13:35:55 -08:00
Rob Rix
6d7cfbaa53
Import Free
.
2015-11-17 13:35:52 -08:00
Rob Rix
9c6a1f3ccb
s/AST/Syntax/
2015-11-17 13:32:14 -08:00
Rob Rix
cc4cf569c1
Remove AST.
2015-11-17 13:31:38 -08:00
Rob Rix
cb80d7de54
Derive Show and Eq.
2015-11-17 13:31:17 -08:00
Rob Rix
06c5dfe9ed
Syntax is a functor.
2015-11-17 13:30:20 -08:00
Rob Rix
538f5355b2
Add a module defining Syntax.
2015-11-17 13:29:55 -08:00
Rob Rix
575398e531
Add the Haskell spike.
2015-11-17 13:25:36 -08:00
Josh Vera
bdbc208024
Merge pull request #233 from github/optimized-diffing-within-leaves
...
Optimized diffing within leaves
2015-11-13 10:42:45 -05:00
Rob Rix
23f050ab81
Correct a test.
2015-11-12 18:12:04 -05:00
Rob Rix
aed17adfed
Remove the unflattened implementation.
2015-11-12 18:01:23 -05:00
Rob Rix
561045ced4
Flatten out equality over Cofree.
2015-11-12 18:01:12 -05:00
Rob Rix
e7b1f59658
Switch through the term directly.
2015-11-12 17:46:18 -05:00
Rob Rix
4d3c335146
Use a single cost function for both diffs.
2015-11-12 17:44:52 -05:00
Rob Rix
822ce7ccc5
Add a Cofree.size
function.
...
This should avoid the protocol indirection around `TermType`.
2015-11-12 17:44:35 -05:00
Rob Rix
8cf0ef097c
Patch.sum/difference are not allowed to throw.
2015-11-12 17:43:32 -05:00
Rob Rix
3f81b9d8b9
Inline size computations on Patch
.
2015-11-12 17:35:34 -05:00
Rob Rix
7da058ca55
Manually fuse TermType.size
.
2015-11-12 17:27:07 -05:00
Rob Rix
ab615dc84e
Manually fuse the map and catamorphism in Free.sum
.
2015-11-12 17:09:19 -05:00
Rob Rix
b0054aee54
Remove Free.reduce
.
2015-11-12 17:00:05 -05:00
Rob Rix
77e9778f91
Remove the unused Interpreter.cost
static function.
2015-11-12 16:59:56 -05:00
Rob Rix
f2004a22b8
Inline reduction in Free.sum
.
2015-11-12 16:55:11 -05:00
Rob Rix
2963a76943
Simplify the refineLeafReplacement
function.
2015-11-12 16:54:55 -05:00
Rob Rix
b276045348
Remove cons
.
2015-11-12 16:13:31 -05:00
Rob Rix
82a8f095cf
Inline calls to cons
.
2015-11-12 16:13:23 -05:00
Rob Rix
4a356a8a0a
Remove costOfStream
.
2015-11-12 16:10:23 -05:00
Rob Rix
b8fb48d723
Remove min
.
2015-11-12 16:10:19 -05:00
Rob Rix
dac24bbf24
µ-optimizations for SES.
...
1. Avoid redundant computations of cost on the fast path (equal
elements at this vertex).
2. Don’t call `min`; inline the branches instead.
3. Don’t call `costOfStream`; inline the costs instead.
2015-11-12 16:09:53 -05:00
Rob Rix
5253de2ef5
Inline stream costs.
2015-11-12 15:58:14 -05:00
Rob Rix
17b9c0a9ec
Fast fail on out of bounds diagonals.
2015-11-12 15:58:03 -05:00
Rob Rix
e1f38f64d0
Precompute the width of the matrix.
2015-11-12 15:26:50 -05:00
Rob Rix
dd812a2b2b
Test that we aren’t at the endIndex
instead of testing containment.
...
This should be O(1) for all index types.
2015-11-12 15:20:51 -05:00