Rob Rix
|
a0253de5bf
|
Don’t wrap the contents of empty lines.
|
2015-12-10 11:06:04 -05:00 |
|
joshvera
|
5c9f2762dd
|
Remove EmptyRow case
|
2015-12-10 10:59:46 -05:00 |
|
Rob Rix
|
da2c1505f3
|
Provide a total definition of unLine.
Fixes #304.
|
2015-12-10 10:59:07 -05:00 |
|
Rob Rix
|
b5f9536bcb
|
Split up the definition of Line.
|
2015-12-10 10:59:07 -05:00 |
|
Rob Rix
|
641ba9b7b7
|
🔥 bimap.
|
2015-12-10 10:58:23 -05:00 |
|
Rob Rix
|
84a817b6bf
|
Rewrap the rows in uls.
|
2015-12-10 10:57:47 -05:00 |
|
Rob Rix
|
e86b43380f
|
Add a rewrap function.
|
2015-12-10 10:57:47 -05:00 |
|
joshvera
|
18c95e0b87
|
Fix inserted ranges returned from diffToRows
|
2015-12-10 10:53:47 -05:00 |
|
joshvera
|
9039068a5c
|
intersperse commas in Show Line instance
|
2015-12-09 19:06:29 -05:00 |
|
joshvera
|
79d8924b58
|
Remove maybeFirstNewLine
|
2015-12-09 18:50:31 -05:00 |
|
joshvera
|
40cc463a90
|
simplify appending a row with two newlines
|
2015-12-09 17:40:41 -05:00 |
|
joshvera
|
72a00b0a15
|
Remove adjoinRows
|
2015-12-09 16:59:40 -05:00 |
|
joshvera
|
088139ed27
|
Delete comments
|
2015-12-09 16:55:26 -05:00 |
|
joshvera
|
d98e8f0801
|
don't append if both sides start with newlines
|
2015-12-09 16:52:06 -05:00 |
|
Rob Rix
|
940be43244
|
Show instances which make it easier to tell where rows start and end.
|
2015-12-09 15:22:29 -05:00 |
|
Rob Rix
|
6f53ed41cf
|
Sp.
|
2015-12-09 15:07:30 -05:00 |
|
joshvera
|
2fe4f74b69
|
remove comments
|
2015-12-09 14:35:18 -05:00 |
|
joshvera
|
888a2bbf8a
|
Remove all uses of adjoinRows
|
2015-12-09 14:32:00 -05:00 |
|
joshvera
|
51fb407004
|
Don't adjoin lines if they start with newlines
|
2015-12-09 13:41:36 -05:00 |
|
joshvera
|
dd54f61206
|
Remove adjoinRows from the equation
|
2015-12-09 13:30:51 -05:00 |
|
joshvera
|
dc456afc65
|
add newline to the end of Row toMarkup
|
2015-12-09 11:25:38 -05:00 |
|
Rob Rix
|
ccfb9ce050
|
Equal category sets also render terms as comparable.
|
2015-12-09 10:59:13 -05:00 |
|
Rob Rix
|
b59623bf3d
|
Construct a parser for the lines in some input file.
|
2015-12-09 10:32:22 -05:00 |
|
Rob Rix
|
f8d43dcfad
|
Add a Parser module/type.
|
2015-12-09 09:49:24 -05:00 |
|
joshvera
|
c67ff8f2e5
|
working through adjoin2
|
2015-12-08 19:52:38 -05:00 |
|
joshvera
|
bcb935c49b
|
add maybeFirstNewLine to look in Uls for new lines
|
2015-12-08 18:09:45 -05:00 |
|
joshvera
|
f86f12b7f6
|
Produce empty lines
|
2015-12-08 12:35:58 -05:00 |
|
Rob Rix
|
04ea70629e
|
Declare the type for textElements.
|
2015-12-08 12:17:11 -05:00 |
|
joshvera
|
5402a2bfbc
|
Add exhaustive cases to some functions
|
2015-12-08 12:14:36 -05:00 |
|
joshvera
|
e9975fea2b
|
Change Row constructor to be Row Line Line
|
2015-12-08 12:08:19 -05:00 |
|
joshvera
|
ef038150db
|
docs
|
2015-12-07 21:53:51 -05:00 |
|
Rob Rix
|
62238923f5
|
Remove an unused function.
|
2015-12-07 16:43:32 -05:00 |
|
Rob Rix
|
2e81d0779a
|
Wrap replacements in divs.
|
2015-12-07 16:43:24 -05:00 |
|
Rob Rix
|
4a57146eb2
|
Wrap deletions in divs.
|
2015-12-07 16:35:39 -05:00 |
|
Rob Rix
|
f46f1b26cd
|
Wrap insertions in divs.
|
2015-12-07 16:35:14 -05:00 |
|
Rob Rix
|
59db60917a
|
Add a div constructor to HTML.
|
2015-12-07 16:30:42 -05:00 |
|
Rob Rix
|
9a307a96ca
|
Revert "Rows contain sets of classnames"
This reverts commit c92ee7ac015827a891398f48f446c1a1d5252056.
|
2015-12-07 16:28:34 -05:00 |
|
Rob Rix
|
aed70270f9
|
Revert "display classes in ToMarkup Row instance"
This reverts commit 0c155677853039ba10258fdbec0a02f121bea4e4.
|
2015-12-07 16:28:26 -05:00 |
|
Rob Rix
|
d7a77f217f
|
Don’t wrap text nodes in dd nodes.
|
2015-12-07 16:22:26 -05:00 |
|
Rob Rix
|
83f9bab9f7
|
Don’t wrap text nodes in li nodes.
|
2015-12-07 16:21:59 -05:00 |
|
Rob Rix
|
c88d81a021
|
Rename rightElements → elements.
|
2015-12-07 16:05:23 -05:00 |
|
joshvera
|
0a3ff0438c
|
display classes in ToMarkup Row instance
|
2015-12-07 15:45:04 -05:00 |
|
joshvera
|
4061be6240
|
Rows contain sets of classnames
|
2015-12-07 15:37:42 -05:00 |
|
Rob Rix
|
49910d1d1e
|
Render HTML to Html.
|
2015-12-07 14:34:58 -05:00 |
|
Rob Rix
|
b172f3c06c
|
Classes are prefixed with category- .
|
2015-12-07 12:15:58 -05:00 |
|
Rob Rix
|
96a87ef716
|
Self-closing element.
|
2015-12-07 12:12:57 -05:00 |
|
Rob Rix
|
6af10f07ed
|
Add a diff class to the table.
|
2015-12-07 12:12:52 -05:00 |
|
Rob Rix
|
8885f039c4
|
Add a head with a link to CSS.
|
2015-12-07 12:03:56 -05:00 |
|
Rob Rix
|
eb9c64d57c
|
Split across lines & indent.
|
2015-12-07 12:03:49 -05:00 |
|
Rob Rix
|
191b818255
|
Show only the rows and concatenate them.
|
2015-12-07 11:59:44 -05:00 |
|
Rob Rix
|
59d8d28779
|
Add newlines after rows.
|
2015-12-07 11:59:26 -05:00 |
|
Rob Rix
|
8d7ebed794
|
Concat the columns.
|
2015-12-07 11:53:04 -05:00 |
|
Rob Rix
|
78d077b2fd
|
Implement the Show instance for Row manually.
|
2015-12-07 11:49:35 -05:00 |
|
Rob Rix
|
3a0479f3fe
|
Define li, dd, and dt showing with tag.
|
2015-12-07 11:49:13 -05:00 |
|
Rob Rix
|
2c680cd205
|
Add a tag function to wrap text in an HTML tag.
|
2015-12-07 11:49:03 -05:00 |
|
Rob Rix
|
22511e3b7b
|
li/dd don’t wrap text nodes.
|
2015-12-07 11:44:40 -05:00 |
|
Rob Rix
|
3c985f0a00
|
Wrap ul/dl children in li/dd respectively.
|
2015-12-07 11:43:37 -05:00 |
|
Rob Rix
|
7db09a14f2
|
Add an explicit Show instance for HTML.
|
2015-12-07 11:42:07 -05:00 |
|
Rob Rix
|
ca753e76ac
|
Rephrase the Show instance for Maybe ClassName as a showClassName function.
|
2015-12-07 11:39:48 -05:00 |
|
Rob Rix
|
7abeee0671
|
Add a custom Show instance for Maybe ClassName.
|
2015-12-07 11:35:49 -05:00 |
|
joshvera
|
8f659d36c0
|
try to print split diffs
|
2015-12-04 16:12:56 -05:00 |
|
joshvera
|
414191afd0
|
implement diffToRows Replace
|
2015-12-04 16:07:27 -05:00 |
|
joshvera
|
66c81b72cc
|
termToLines produces lines
|
2015-12-04 15:54:40 -05:00 |
|
joshvera
|
b4947255cf
|
add adjoinLines
|
2015-12-04 15:54:07 -05:00 |
|
joshvera
|
090635cd59
|
add a Monoid instance for Line
|
2015-12-04 15:54:03 -05:00 |
|
joshvera
|
4e24b26440
|
factor out termToLines/textElements
|
2015-12-04 15:40:27 -05:00 |
|
joshvera
|
39df978cb7
|
insert Indexed rows
|
2015-12-04 15:05:43 -05:00 |
|
joshvera
|
0b558516a9
|
insert Leaves
|
2015-12-04 14:43:15 -05:00 |
|
joshvera
|
a8dfa0c665
|
stub insertToRows
|
2015-12-04 14:39:06 -05:00 |
|
joshvera
|
e15ecb934f
|
factoring
|
2015-12-04 14:23:22 -05:00 |
|
joshvera
|
438cb5f04c
|
Promote through empty columns
|
2015-12-04 14:18:26 -05:00 |
|
joshvera
|
c0c94a3be9
|
Remove splitDiff/splitPatch/termToHTML
|
2015-12-04 14:17:14 -05:00 |
|
joshvera
|
77ef9808f0
|
remove some imports
|
2015-12-04 14:16:54 -05:00 |
|
joshvera
|
50a1e682bc
|
Implement actualLines to handle newlines at the end of text
|
2015-12-04 12:02:26 -05:00 |
|
joshvera
|
4389a08a95
|
spaces
|
2015-12-04 11:26:03 -05:00 |
|
joshvera
|
e0e5c02926
|
Move functions out to contextRows, starts, and ends
|
2015-12-04 11:24:42 -05:00 |
|
Rob Rix
|
00852e5cab
|
Rewrite zipMaybe as zipWithMaybe .
|
2015-12-04 10:52:47 -05:00 |
|
Rob Rix
|
1516957fec
|
Use the left/right child ranges.
|
2015-12-04 10:50:00 -05:00 |
|
Rob Rix
|
563973e210
|
Use starts/ends.
|
2015-12-04 10:48:04 -05:00 |
|
Rob Rix
|
f76335f38a
|
Add functions to get a pair of start/end indices from a pair of ranges.
|
2015-12-04 10:47:58 -05:00 |
|
Rob Rix
|
cc48afb663
|
Nest the start/end range & index tuples so we don’t need to destructure them.
|
2015-12-04 10:46:47 -05:00 |
|
Rob Rix
|
59e6577f5e
|
Correct the accumulation of the terminal context.
|
2015-12-04 10:43:45 -05:00 |
|
Rob Rix
|
fe5b6d2011
|
We don’t need this annotation.
|
2015-12-04 10:40:11 -05:00 |
|
Rob Rix
|
31e5cc9353
|
Rearrange the rows/indices to match the function return.
|
2015-12-04 10:39:05 -05:00 |
|
Rob Rix
|
62223655a6
|
Adjoin the context & child rows.
|
2015-12-04 10:28:46 -05:00 |
|
Rob Rix
|
618a43a00d
|
Clarify which ranges we’re fetching to the end of.
|
2015-12-04 10:25:54 -05:00 |
|
Rob Rix
|
015e2d9437
|
adjoinRows has a right identity as well.
|
2015-12-04 10:22:54 -05:00 |
|
Rob Rix
|
dbdf194f6a
|
Adjoin the final context.
|
2015-12-04 10:20:26 -05:00 |
|
Rob Rix
|
7648c65e52
|
Append the remainder of the context.
|
2015-12-04 10:06:49 -05:00 |
|
Rob Rix
|
2bacc86086
|
Add a function to append the remainder of the context as text nodes.
|
2015-12-04 10:06:34 -05:00 |
|
Rob Rix
|
4fe345086d
|
Use the right categories on the right side.
|
2015-12-04 10:01:52 -05:00 |
|
Rob Rix
|
e6c96ed60b
|
Wrap indexed Row s elements in Ul elements.
|
2015-12-04 10:00:50 -05:00 |
|
Rob Rix
|
2b06e3cc10
|
Implement bimap over Row .
`Row` isn’t actually a proper `Bifunctor` because it doesn’t have type
parameters, but we can still implement the function ourselves.
|
2015-12-04 10:00:25 -05:00 |
|
Rob Rix
|
19ff0415d6
|
Add a convenience to construct the complete range of a list.
|
2015-12-04 09:20:23 -05:00 |
|
Rob Rix
|
2c36e0cc7c
|
Rename annotationAndSyntaxToRows to annotatedToRows.
|
2015-12-03 17:57:26 -05:00 |
|
Rob Rix
|
1b2f5a6786
|
Pass the annotation to annotationAndSyntaxToRows.
|
2015-12-03 16:35:28 -05:00 |
|
Rob Rix
|
15481e317d
|
Rename accumualteContext to sumRows .
|
2015-12-03 16:30:40 -05:00 |
|
Rob Rix
|
fd0245129d
|
Unpack the child elements in the where clause.
|
2015-12-03 16:29:42 -05:00 |
|
Rob Rix
|
e250dd74af
|
Use the correct string.
|
2015-12-03 16:29:17 -05:00 |
|
Rob Rix
|
db994a1b6f
|
Remove splitHTMLIntoLines and friends.
|
2015-12-03 16:26:51 -05:00 |
|
Rob Rix
|
bdc6c7625e
|
Remove Line.
|
2015-12-03 16:25:17 -05:00 |
|
Rob Rix
|
6c273c30c8
|
Remove adjoinLines.
|
2015-12-03 16:25:11 -05:00 |
|
Rob Rix
|
6750c251b6
|
Adjoin non-empty lists of rows.
|
2015-12-03 16:11:21 -05:00 |
|
Rob Rix
|
db1a4490ee
|
Row is defined over two lists of HTML elements.
|
2015-12-03 16:11:21 -05:00 |
|
Rob Rix
|
157d421953
|
Remove the commented examples.
|
2015-12-03 16:11:21 -05:00 |
|
Rob Rix
|
dd7450ff6e
|
Stub in adjoinRows with the identity case.
|
2015-12-03 12:26:36 -05:00 |
|
Rob Rix
|
9ac697834e
|
Row is Equatable and can be Shown.
|
2015-12-03 12:26:25 -05:00 |
|
Rob Rix
|
56a8386473
|
Append the last on the left to the first on the right.
|
2015-12-03 12:13:47 -05:00 |
|
Rob Rix
|
9459b28935
|
Destructure and append the first lines only.
|
2015-12-03 12:09:28 -05:00 |
|
Rob Rix
|
dc71ae150d
|
Identity case.
|
2015-12-03 12:03:16 -05:00 |
|
Rob Rix
|
1f6ef522c6
|
Concatenate lines.
|
2015-12-03 11:57:13 -05:00 |
|
Rob Rix
|
6d13e98b6a
|
Line is a Monoid.
|
2015-12-03 11:57:09 -05:00 |
|
Rob Rix
|
6ef2eb89fc
|
Return the current element.
|
2015-12-03 11:52:02 -05:00 |
|
Rob Rix
|
cfda7c8ff2
|
Export everything for testing.
|
2015-12-03 11:50:51 -05:00 |
|
Rob Rix
|
8e66656105
|
Document adjoinLines a little.
|
2015-12-03 11:47:42 -05:00 |
|
Rob Rix
|
af105ebb88
|
derive Eq
|
2015-12-03 11:42:44 -05:00 |
|
Rob Rix
|
9a729a246b
|
Export adjoinLines.
|
2015-12-03 11:41:15 -05:00 |
|
Rob Rix
|
a90a22e454
|
Stub in a function to adjoin pairs of lines.
|
2015-12-03 11:41:02 -05:00 |
|
Rob Rix
|
720c3c0dba
|
Add a Line type.
|
2015-12-03 11:40:54 -05:00 |
|
Rob Rix
|
bbcb3be6fc
|
Move Split & Unified into the library.
|
2015-12-03 11:37:18 -05:00 |
|
joshvera
|
2a063d3277
|
Move Range to a module
|
2015-12-02 21:40:34 -05:00 |
|
joshvera
|
1dd8d93ce1
|
use fromIntegral
|
2015-12-02 14:29:19 -05:00 |
|
Rob Rix
|
1b5f6b848d
|
stub line ranges in Info
|
2015-12-01 14:51:21 -05:00 |
|
Rob Rix
|
90b1cce022
|
Minimal summation of diffs.
|
2015-12-01 10:13:05 -05:00 |
|
Rob Rix
|
932e07d47d
|
Annotated is Foldable.
|
2015-12-01 10:12:52 -05:00 |
|
Rob Rix
|
7740654d68
|
diffCost sums term sizes.
|
2015-11-30 19:16:22 -05:00 |
|
Rob Rix
|
5069014381
|
Compute the size of terms.
|
2015-11-30 19:13:20 -05:00 |
|
Rob Rix
|
f00b8c3e7d
|
Add a patchSum function.
|
2015-11-30 19:08:28 -05:00 |
|
Rob Rix
|
4c403422ce
|
Add a diffSum function.
|
2015-11-30 19:06:48 -05:00 |
|
Rob Rix
|
6c2bde6bd0
|
Cache invalidation.
|
2015-11-30 18:25:59 -05:00 |
|
Rob Rix
|
6fd8ad90d5
|
SES calls into diffAt.
|
2015-11-30 18:17:30 -05:00 |
|
Rob Rix
|
149b80e1da
|
Perform the diff in the general case.
|
2015-11-30 18:17:21 -05:00 |
|
Rob Rix
|
a76f645f63
|
Abstract over type parameters.
|
2015-11-30 18:17:15 -05:00 |
|
Rob Rix
|
b0762f5e5f
|
Remove an unnecessary $.
|
2015-11-30 17:52:45 -05:00 |
|
Rob Rix
|
7ef0800b75
|
Remove the copy binding.
|
2015-11-30 17:50:23 -05:00 |
|
Rob Rix
|
56b4ae6ea3
|
Short-circuit at end of a/b attributes costs.
|
2015-11-30 17:47:32 -05:00 |
|
Rob Rix
|
4cd988b89b
|
Delete/insert are consed with costs.
|
2015-11-30 17:47:10 -05:00 |
|
Rob Rix
|
f68d7c253a
|
Compute cost and cons together edit scripts at once.
|
2015-11-30 17:37:13 -05:00 |
|
Rob Rix
|
827ae6374a
|
Produce diff/cost pairs.
|
2015-11-30 17:28:02 -05:00 |
|
Rob Rix
|
b6251522a3
|
Add a function to compute a recursive copy.
|
2015-11-30 17:25:54 -05:00 |
|
Rob Rix
|
bf333bc073
|
Add delete & insert bindings.
|
2015-11-30 17:25:43 -05:00 |
|
Rob Rix
|
37f6c02432
|
Add a recur function closing over the operands.
|
2015-11-30 17:25:18 -05:00 |
|
Rob Rix
|
3f6caffb04
|
sumCost sums the cost fields.
|
2015-11-30 17:24:54 -05:00 |
|
Rob Rix
|
1d99c50a44
|
Add a best function.
|
2015-11-30 17:08:28 -05:00 |
|
Rob Rix
|
f511c85691
|
The indices come after the functions.
|
2015-11-30 17:08:08 -05:00 |
|
Rob Rix
|
ea6369bdb1
|
Parameterize by the comparison function.
|
2015-11-30 16:58:21 -05:00 |
|
Rob Rix
|
29475a1ef6
|
Bring the sumCost function over.
|
2015-11-30 16:57:23 -05:00 |
|
Rob Rix
|
e1cd992155
|
Parameterize by the cost function.
|
2015-11-30 16:57:14 -05:00 |
|
Rob Rix
|
f714539691
|
Rename the state variable.
|
2015-11-30 16:55:22 -05:00 |
|
Rob Rix
|
461c7629c9
|
We’re going to need these.
|
2015-11-30 16:54:51 -05:00 |
|
Rob Rix
|
1704369fdc
|
We don’t use these bindings.
|
2015-11-30 16:53:04 -05:00 |
|
Rob Rix
|
b0b43cf3b0
|
Eliminate with pattern matching.
|
2015-11-30 16:51:45 -05:00 |
|
Rob Rix
|
6b61eb7777
|
Attempt to stub in computation of the rest of the diff.
|
2015-11-30 16:48:33 -05:00 |
|
Rob Rix
|
3429f52e3f
|
Move the return inside the handling of the Just case.
|
2015-11-30 16:45:54 -05:00 |
|
Rob Rix
|
7793a8de2f
|
Stub in caching & computation.
|
2015-11-30 16:44:41 -05:00 |
|
Rob Rix
|
f81de8d289
|
Get the state in the general case.
|
2015-11-30 16:25:00 -05:00 |
|
Rob Rix
|
47f3b61395
|
Diffing a non-empty list against an empty list produces deletions.
|
2015-11-30 16:23:34 -05:00 |
|
Rob Rix
|
0d2e881405
|
Diffing an empty list against a non-empty list produces insertions.
|
2015-11-30 16:21:41 -05:00 |
|
Rob Rix
|
df23b3af23
|
Diffing empty lists produces an empty diff.
|
2015-11-30 16:19:34 -05:00 |
|
Rob Rix
|
e4c7ce28c0
|
Remove needless parens.
|
2015-11-30 16:17:37 -05:00 |
|
Rob Rix
|
4a3c63473e
|
Import Map qualified.
|
2015-11-30 16:17:24 -05:00 |
|
Rob Rix
|
efee13fd63
|
Stub in a diffAt function.
|
2015-11-30 16:02:37 -05:00 |
|
Rob Rix
|
c520a03f7b
|
Correct the sense of categories comparing.
|
2015-11-27 14:49:51 -05:00 |
|
Rob Rix
|
defce6edbf
|
Doc comments 🎩 @joshvera
|
2015-11-27 12:19:24 -05:00 |
|
Rob Rix
|
a2c994b573
|
Avoid some other shadowing.
|
2015-11-27 12:12:49 -05:00 |
|
Rob Rix
|
332f4c2ef2
|
Factor out the annotations.
|
2015-11-27 12:10:16 -05:00 |
|
Rob Rix
|
60961da561
|
We don’t use unwrap and we would otherwise shadow it.
|
2015-11-27 12:07:04 -05:00 |
|
Rob Rix
|
5aa8d4a3c0
|
Rename cost to diffCost .
|
2015-11-27 12:06:14 -05:00 |
|
Rob Rix
|
2e307510b2
|
Don’t shadow the head function.
|
2015-11-27 12:03:48 -05:00 |
|
Rob Rix
|
dcd3fbdf8e
|
We don’t need this import.
|
2015-11-27 12:03:19 -05:00 |
|
Rob Rix
|
4467b4444e
|
Don’t shadow.
|
2015-11-27 12:02:28 -05:00 |
|
Rob Rix
|
2c241e8ad8
|
Move the Categorizable instance.
|
2015-11-27 12:02:15 -05:00 |
|
Rob Rix
|
f89e05b702
|
We don’t use this.
|
2015-11-27 11:58:20 -05:00 |
|
Josh Vera
|
69a0d33ffe
|
Merge pull request #249 from github/sunshine-lollipops-and-rainbows-everywhere
Sunshine lollipops and rainbows everywhere
|
2015-11-27 11:50:47 -05:00 |
|
Rob Rix
|
95750ea60d
|
Use the factored-out annotations.
|
2015-11-27 11:46:25 -05:00 |
|
Rob Rix
|
f4c73cb3f7
|
Extract the annotation of Free terms.
|
2015-11-27 11:46:12 -05:00 |
|
Rob Rix
|
b814e3c068
|
Merge branch 'master' into apply-review-feedback
|
2015-11-27 11:42:10 -05:00 |
|
Rob Rix
|
bb9bf71d17
|
Merge branch 'master' into sunshine-lollipops-and-rainbows-everywhere
# Conflicts:
# semantic-diff.cabal
|
2015-11-27 11:36:18 -05:00 |
|
Rob Rix
|
99e383a644
|
Move Console and Unified into the exe.
|
2015-11-27 10:14:12 -05:00 |
|
Rob Rix
|
45a865698b
|
Explicitly error if maybeInterpret’s assumptions are violated.
|
2015-11-27 10:04:53 -05:00 |
|
Rob Rix
|
edfc082a36
|
Single-line formatting.
|
2015-11-27 09:55:29 -05:00 |
|
Rob Rix
|
fe07b475e4
|
Use fromMaybe to unpack with a default value.
I was looking for exactly this! Very nice.
|
2015-11-27 09:53:37 -05:00 |
|
Rob Rix
|
982fe363d8
|
Sort imports.
|
2015-11-27 09:51:59 -05:00 |
|
Rob Rix
|
3be2d11b13
|
Remove the delete/insert costs.
|
2015-11-27 09:49:51 -05:00 |
|
Rob Rix
|
062d54d731
|
Use a better name for the argument to sum .
|
2015-11-27 09:49:32 -05:00 |
|
Rob Rix
|
53e3928b3d
|
Don’t close over the head of the list.
|
2015-11-27 09:46:51 -05:00 |
|
Rob Rix
|
1808f61221
|
Remove copyCost .
|
2015-11-27 09:46:38 -05:00 |
|
Rob Rix
|
3a52a5c2b6
|
Use minimumBy to implement the insert/delete choice too.
|
2015-11-27 09:45:23 -05:00 |
|
Rob Rix
|
63e3252129
|
Use minimumBy to implement the SES choice.
|
2015-11-27 09:44:49 -05:00 |
|
Rob Rix
|
ab05599dab
|
Sort imports.
|
2015-11-27 09:44:29 -05:00 |
|
Rob Rix
|
05fa421642
|
Document Syntax.
|
2015-11-27 09:41:43 -05:00 |
|
Rob Rix
|
df7d79bc62
|
This is also a Term.
|
2015-11-27 09:31:56 -05:00 |
|
Rob Rix
|
13edc3c832
|
Derive a Traversable instance for Syntax.
|
2015-11-25 10:58:47 -05:00 |
|
Rob Rix
|
abf8c693b3
|
Derive a Foldable instance for Syntax .
|
2015-11-25 10:58:02 -05:00 |
|
Rob Rix
|
d51c6ba618
|
s/recur/diffTerms/
|
2015-11-25 09:40:45 -05:00 |
|
Rob Rix
|
9c4521bd0e
|
Style insertions and deletions.
|
2015-11-20 08:06:44 -08:00 |
|
Rob Rix
|
5617cceee2
|
Format strings with attributes.
|
2015-11-19 23:07:43 -08:00 |
|
Rob Rix
|
f0286335fb
|
Add an Attribute type with colour & style fields.
|
2015-11-19 21:43:19 -08:00 |
|
Rob Rix
|
dbaf71233b
|
Style is an Enum.
|
2015-11-19 18:02:21 -08:00 |
|
Rob Rix
|
e9174bda71
|
Style is Bounded.
|
2015-11-19 18:02:11 -08:00 |
|
Rob Rix
|
38610c8336
|
Add Style .
|
2015-11-19 18:02:02 -08:00 |
|
Rob Rix
|
8318a8aa89
|
Colour is an Enum.
|
2015-11-19 18:01:56 -08:00 |
|
Rob Rix
|
0b0d8097fb
|
Colour is Bounded.
|
2015-11-19 18:01:50 -08:00 |
|
Rob Rix
|
92a5eb1688
|
Add a Colour type.
|
2015-11-19 18:00:03 -08:00 |
|
Rob Rix
|
09cda9d15f
|
Stub in a Console module.
|
2015-11-19 17:39:21 -08:00 |
|
Rob Rix
|
678c61f5b0
|
Only render unified .
|
2015-11-19 17:38:21 -08:00 |
|
Rob Rix
|
54e3ac9ce9
|
Render the after state of patches.
|
2015-11-19 17:37:45 -08:00 |
|
Rob Rix
|
55d9cfb129
|
Unified rendering of patches.
|
2015-11-19 17:36:59 -08:00 |
|
Rob Rix
|
cbd1c962ca
|
Flip unifiedTerm .
|
2015-11-19 17:36:51 -08:00 |
|
Rob Rix
|
75325e7ef0
|
Add a change function which wraps a string in braces with some marker.
|
2015-11-19 17:36:38 -08:00 |
|
Rob Rix
|
02b07b70d8
|
Add a before function.
|
2015-11-19 17:25:28 -08:00 |
|
Rob Rix
|
69d797f135
|
Patches are annotated with Info .
|
2015-11-19 17:23:41 -08:00 |
|
Rob Rix
|
8fe1fc6ff2
|
Unified rendering of terms.
|
2015-11-19 17:23:12 -08:00 |
|
Rob Rix
|
7abc918f18
|
Hide foldl .
|
2015-11-19 17:23:06 -08:00 |
|
Rob Rix
|
389f0a0983
|
Unpack Annotated separately.
|
2015-11-19 17:22:55 -08:00 |
|
Rob Rix
|
f40fc7e117
|
cata over Term .
|
2015-11-19 17:17:17 -08:00 |
|
Rob Rix
|
d916df923c
|
Stub in unifiedTerm.
|
2015-11-19 16:27:31 -08:00 |
|
Rob Rix
|
ec0c6fb584
|
Unified rendering of keyed diffs.
|
2015-11-19 16:24:07 -08:00 |
|
Rob Rix
|
7b6277994f
|
Delete the String/Range ord.
|
2015-11-19 16:23:45 -08:00 |
|
Rob Rix
|
4474739427
|
Range is ordered.
|
2015-11-19 16:23:18 -08:00 |
|
Rob Rix
|
417f27cc39
|
String/range pairs are ordered.
|
2015-11-19 16:07:30 -08:00 |
|
Rob Rix
|
0702ad277d
|
Import Data.Map.
|
2015-11-19 15:59:24 -08:00 |
|
Rob Rix
|
8970033077
|
Unified rendering of fixed diffs.
|
2015-11-19 15:58:56 -08:00 |
|
Rob Rix
|
360b134438
|
Unified rendering of indexed diffs.
|
2015-11-19 15:58:41 -08:00 |
|
Rob Rix
|
6fa7204728
|
Accumulate context between children.
|
2015-11-19 15:56:58 -08:00 |
|
Rob Rix
|
b133e572c7
|
Implement unifiedRange w/o initial context.
|
2015-11-19 15:53:37 -08:00 |
|
Rob Rix
|
14e7b6ae08
|
Return pairs of strings/ranges.
|
2015-11-19 15:53:23 -08:00 |
|
Rob Rix
|
73838c7844
|
Extract the range from patches.
|
2015-11-19 15:30:37 -08:00 |
|
Rob Rix
|
69e2efc977
|
Get the after state out of Patches.
|
2015-11-19 15:26:40 -08:00 |
|
Rob Rix
|
a254d1168e
|
Stub in unifiedRange .
|
2015-11-19 15:08:11 -08:00 |
|
Rob Rix
|
660e21345c
|
Unified rendering of leaves produces the substring.
|
2015-11-19 15:06:42 -08:00 |
|
Rob Rix
|
0d7261454e
|
unified operates over diffs annotated with Info .
|
2015-11-19 15:06:25 -08:00 |
|
Rob Rix
|
4103cfb1e2
|
Substrings.
|
2015-11-19 15:05:33 -08:00 |
|
Rob Rix
|
222aba8e46
|
Ranges have Int bounds.
|
2015-11-19 15:05:29 -08:00 |
|
Rob Rix
|
0cd3b8c16c
|
Stub in the implementation of unified over Diff .
|
2015-11-19 14:37:07 -08:00 |
|
Rob Rix
|
a5729774d0
|
Stub in the type of unified .
|
2015-11-19 14:36:32 -08:00 |
|
Rob Rix
|
0c6ba1f3a6
|
Info uses the Category type.
|
2015-11-19 14:36:07 -08:00 |
|
Rob Rix
|
1394b60d2c
|
Add a Category type name.
|
2015-11-19 14:35:46 -08:00 |
|
Rob Rix
|
0fdb2469f9
|
Stub in a Unified diff renderer file.
|
2015-11-19 13:35:06 -08:00 |
|
Rob Rix
|
486f3a4732
|
Factor out a pattern match.
|
2015-11-19 12:20:57 -08:00 |
|
Rob Rix
|
0cced151ea
|
Remove some obsolete imports.
|
2015-11-19 12:13:45 -08:00 |
|
Rob Rix
|
4298956f37
|
Info is Categorizable.
|
2015-11-19 12:06:34 -08:00 |
|
Rob Rix
|
7138d9fb1b
|
Info has a Range and a set of categories.
|
2015-11-19 12:04:18 -08:00 |
|
Rob Rix
|
53b6c6846c
|
Ranges are equatable and showable.
|
2015-11-19 12:02:53 -08:00 |
|
Rob Rix
|
c925543305
|
constructAndRun for equal terms.
|
2015-11-19 11:56:45 -08:00 |
|
Rob Rix
|
87c7a0b6b0
|
Implement hylomorphism.
|
2015-11-19 11:56:35 -08:00 |
|
Rob Rix
|
6c6d72601d
|
Factor out more annotation unpacking.
|
2015-11-19 11:37:19 -08:00 |
|
Rob Rix
|
c2dc659a57
|
Factor out annotation unpacking.
|
2015-11-19 11:36:14 -08:00 |
|
Rob Rix
|
e6385e2832
|
Diffs are annotated.
|
2015-11-19 11:27:31 -08:00 |
|
Rob Rix
|
2a081c5aa0
|
Keyed nodes.
|
2015-11-18 18:00:10 -08:00 |
|
Rob Rix
|
21d9bb3670
|
Compose some more functions.
|
2015-11-18 17:38:48 -08:00 |
|
Rob Rix
|
e91bdbd981
|
Factor out the operator section.
|
2015-11-18 17:35:03 -08:00 |
|
Rob Rix
|
63dfb9d08b
|
Zip Fixed terms.
|
2015-11-18 17:35:03 -08:00 |
|
Rob Rix
|
d317e32284
|
Zip Indexed terms.
|
2015-11-18 17:35:03 -08:00 |
|
Rob Rix
|
0b3c04fe1b
|
Zip leaf terms.
|
2015-11-18 17:35:03 -08:00 |
|
Rob Rix
|
e8274ed379
|
Zip terms.
|
2015-11-18 17:35:03 -08:00 |
|
Rob Rix
|
ee4da4218d
|
Add an Annotated syntax type.
|
2015-11-18 17:35:03 -08:00 |
|
Rob Rix
|
c595fda525
|
Ranges are bounded by integers.
|
2015-11-18 17:35:03 -08:00 |
|
Rob Rix
|
680465dfbf
|
Abstract Diff over an annotation type.
|
2015-11-18 13:23:47 -08:00 |
|
Rob Rix
|
359c1818d0
|
Use const .
|
2015-11-18 12:09:08 -08:00 |
|
Rob Rix
|
c7336dae2c
|
Remove Data.Fix .
|
2015-11-18 11:54:08 -08:00 |
|
Rob Rix
|
e74340d4cf
|
🔥 the RangedWhatever things.
|
2015-11-18 11:50:30 -08:00 |
|
Rob Rix
|
5129bc455b
|
Move the diff fixture thing to the executable.
|
2015-11-18 11:45:23 -08:00 |
|
Rob Rix
|
1e3ae866c2
|
Terms with Categorizable annotations are themselves Categorizable.
|
2015-11-18 11:39:08 -08:00 |
|
Rob Rix
|
a47ad36d98
|
Move the definition of Term into the Term module.
|
2015-11-18 11:28:16 -08:00 |
|
Rob Rix
|
e989216361
|
Add a Term module.
|
2015-11-18 11:27:09 -08:00 |
|
Rob Rix
|
fba97d256b
|
Test whether Categorizable values are comparable.
|
2015-11-18 11:25:53 -08:00 |
|
Rob Rix
|
f1eed7dac2
|
Categorizable things have categories.
|
2015-11-18 11:23:35 -08:00 |
|
Rob Rix
|
5fe7cecba9
|
Add a Categorizable module.
|
2015-11-18 11:23:28 -08:00 |
|
Rob Rix
|
092192cb14
|
Short-circuit for equal terms.
|
2015-11-18 11:21:30 -08:00 |
|
Rob Rix
|
09d10875c3
|
Info is Equatable.
|
2015-11-18 11:19:16 -08:00 |
|
Rob Rix
|
da5807180a
|
If not comparable, don’t compare.
|
2015-11-18 11:13:13 -08:00 |
|
Rob Rix
|
6f49840fc8
|
Comparable tests terms.
|
2015-11-18 11:13:00 -08:00 |
|
Rob Rix
|
fc4cab8120
|
Export Comparable .
|
2015-11-18 11:09:18 -08:00 |
|
Rob Rix
|
0ad19372fd
|
Parameterize interpret by a comparable function.
|
2015-11-18 11:09:11 -08:00 |
|
Rob Rix
|
6e64ada5ad
|
Equal leaves produce equal diffs.
|
2015-11-18 10:59:40 -08:00 |
|
Rob Rix
|
7dae86cba6
|
Recursive for everything else.
|
2015-11-18 10:53:59 -08:00 |
|
Rob Rix
|
57e30d7a57
|
ByKey for Keyed nodes.
|
2015-11-18 10:52:49 -08:00 |
|
Rob Rix
|
dfbb01fda1
|
ByIndex for Indexed nodes.
|
2015-11-18 10:52:09 -08:00 |
|
Rob Rix
|
eeaa77812c
|
Parameterize SES by the cost function.
|
2015-11-18 10:44:02 -08:00 |
|
Rob Rix
|
aabc5f62ee
|
Compose.
|
2015-11-18 10:39:49 -08:00 |
|
Rob Rix
|
c2deb95a36
|
Recur through SES via constructAndRun.
|
2015-11-18 10:39:20 -08:00 |
|
Rob Rix
|
9fd3be3408
|
Capture the copy cost as well.
|
2015-11-18 10:38:29 -08:00 |
|
Rob Rix
|
0799dfa51d
|
Capture insert/delete costs.
|
2015-11-18 10:37:42 -08:00 |
|
Rob Rix
|
40588b9942
|
Guards.
|
2015-11-18 10:36:47 -08:00 |
|
Rob Rix
|
7e75c662dc
|
Diagonals.
|
2015-11-18 10:36:19 -08:00 |
|
Rob Rix
|
ad0c9ca4b2
|
Alias the comparison function’s type.
|
2015-11-18 10:28:07 -08:00 |
|
Rob Rix
|
e7e2f280e1
|
Parameterize by recur .
|
2015-11-18 10:26:40 -08:00 |
|
Rob Rix
|
2b8e3c7dbf
|
Specialize to Term/Diff.
|
2015-11-18 07:44:08 -08:00 |
|
Rob Rix
|
08ce71953e
|
Implement cost .
|
2015-11-18 07:43:10 -08:00 |
|
Rob Rix
|
08f3d217c0
|
Implement SES in terms of cost and recur functions.
|
2015-11-18 07:40:54 -08:00 |
|
Rob Rix
|
6d6fbcf797
|
Go back to Diff SES.
|
2015-11-18 07:40:30 -08:00 |
|
Rob Rix
|
cb6eeff9e3
|
Only export ses .
|
2015-11-18 07:27:54 -08:00 |
|
Rob Rix
|
676ef16162
|
Implement the empty cases by pattern matching.
|
2015-11-18 07:27:19 -08:00 |
|
Rob Rix
|
13499cc520
|
Implement the equal head case of SES.
|
2015-11-18 07:26:24 -08:00 |
|
Rob Rix
|
9bafea4749
|
SES returns both terms.
|
2015-11-18 07:25:42 -08:00 |
|
Rob Rix
|
8b3c1aacfd
|
SES returns Either .
|
2015-11-18 07:25:26 -08:00 |
|
Rob Rix
|
e742cf6859
|
Annotate the type of SES.
I’m not at all sure this is correct.
|
2015-11-18 07:13:55 -08:00 |
|
Rob Rix
|
ae27e9cbbe
|
Move SES into its own file.
|
2015-11-18 07:11:05 -08:00 |
|
Rob Rix
|
b122712470
|
Add a file for SES.
|
2015-11-18 07:09:49 -08:00 |
|
Rob Rix
|
bb43da027a
|
SES over empty/non-empty lists.
|
2015-11-18 07:02:47 -08:00 |
|
Rob Rix
|
a7545ed749
|
Interpret ByKey algorithms.
|
2015-11-18 00:21:27 -08:00 |
|
Rob Rix
|
213d8fbd55
|
Maps all the way down.
|
2015-11-17 18:58:51 -08:00 |
|
Rob Rix
|
e01e4bb923
|
ByKey’s continuation takes a map.
|
2015-11-17 18:56:28 -08:00 |
|
Rob Rix
|
242ca9464b
|
Patch is a Functor.
|
2015-11-17 18:51:36 -08:00 |
|
Rob Rix
|
da3bf047b1
|
Patch is algebraic.
|
2015-11-17 18:44:55 -08:00 |
|
Rob Rix
|
d881006e55
|
Spacing.
|
2015-11-17 18:26:07 -08:00 |
|
Rob Rix
|
e700c407f2
|
Move Patch into its file.
|
2015-11-17 18:23:53 -08:00 |
|
Rob Rix
|
c467437233
|
Add a file for Patch.
|
2015-11-17 18:21:51 -08:00 |
|
Rob Rix
|
ef1e64376c
|
Break repacking out.
|
2015-11-17 18:16:39 -08:00 |
|
Rob Rix
|
a4f83780bd
|
Factor some of the operands out.
|
2015-11-17 17:59:01 -08:00 |
|
Rob Rix
|
9504ebe586
|
Recursive interpretation of Keyed terms.
|
2015-11-17 17:50:15 -08:00 |
|
Rob Rix
|
0d8edc8272
|
Recur through Fixed terms.
|
2015-11-17 17:35:00 -08:00 |
|
Rob Rix
|
e26dbb1fbe
|
Recur through indexed terms of equal length.
|
2015-11-17 17:34:04 -08:00 |
|
Rob Rix
|
e620eb76ff
|
Stub in recurring through indexed terms.
|
2015-11-17 17:29:18 -08:00 |
|
Rob Rix
|
a30328e682
|
Stub in recursive diffing to always replace.
|
2015-11-17 17:29:12 -08:00 |
|
Rob Rix
|
485e947da6
|
Rename to constructAndRun.
|
2015-11-17 17:17:45 -08:00 |
|
Rob Rix
|
cdcb575b57
|
Only export interpret .
|
2015-11-17 17:15:10 -08:00 |
|
Rob Rix
|
16e4bf891d
|
Interpretation.
|
2015-11-17 17:13:48 -08:00 |
|
Rob Rix
|
7c09fd1503
|
Stub in interpretation.
|
2015-11-17 17:05:16 -08:00 |
|
Rob Rix
|
3829f4492d
|
Remove the old interpret function.
|
2015-11-17 17:04:05 -08:00 |
|
Rob Rix
|
b4450e038e
|
Stub in a file for Interpreter.
|
2015-11-17 16:25:39 -08:00 |
|
Rob Rix
|
5438acf1fb
|
Add Algorithm.
|
2015-11-17 16:24:01 -08:00 |
|
Rob Rix
|
aba1b31625
|
Add an Algorithm file.
|
2015-11-17 16:20:52 -08:00 |
|
Rob Rix
|
a71385b22e
|
Indentation stuff.
|
2015-11-17 16:17:42 -08:00 |
|
Rob Rix
|
4028c50c84
|
Remove redundant DeriveFunctor.
|
2015-11-17 15:43:39 -08:00 |
|
Rob Rix
|
af280ae63d
|
Rename the Recursive constructor.
|
2015-11-17 15:40:03 -08:00 |
|
Rob Rix
|
a700b7f7ff
|
Derive functor.
|
2015-11-17 15:39:51 -08:00 |
|
Rob Rix
|
c8b573cb33
|
Move Operation into its own file.
|
2015-11-17 15:14:57 -08:00 |
|
Rob Rix
|
313019fa3a
|
Remove all the parentheses ever.
|
2015-11-17 15:09:42 -08:00 |
|
Rob Rix
|
4f84059c0b
|
Remove redundant.
|
2015-11-17 15:07:06 -08:00 |
|
Rob Rix
|
b2660e2b1c
|
Parenthesize some things.
|
2015-11-17 15:06:24 -08:00 |
|
Rob Rix
|
e5282b9745
|
Remove Lib.hs.
|
2015-11-17 14:54:06 -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 |
|