1
1
mirror of https://github.com/coot/free-category.git synced 2024-11-23 09:55:43 +03:00
Commit Graph

56 Commits

Author SHA1 Message Date
Marcin Szamotulski
5864b3ad7f Optimisations of 'Cat'
Adding INLINE pragmas, optimising order of pattern matches.
2019-09-01 12:09:39 +00:00
Marcin Szamotulski
3b9c127ff8 Adding ViewL to Free.Internal export list 2019-09-01 12:09:39 +00:00
Marcin Szamotulski
be5cfdc552 Optimise internal Queue
Queue contains three 'ListTr', only the middle one, which holds reverse
values, should be forced to weak normal form.  Otherwise the queue will
not be as performant as designed.  A performance gain was measured.

Adding INLINE pragmas had a significant improvemnt in performance of the
queue.
2019-09-01 12:09:39 +00:00
Marcin Szamotulski
166dfc8947 Added hoistQ: Queue is an endo-functor on the category of categories 2019-09-01 12:09:39 +00:00
Marcin Szamotulski
c77fa194f5 Show instances for ListTr and Queue (with QuantifiedConstraints) 2019-09-01 12:09:39 +00:00
Marcin Szamotulski
d4966a6108 Fixed a bug in 'uncons'
Make `Queue.uncons` perserve `Queue` invariant.
2019-09-01 12:09:39 +00:00
Marcin Szamotulski
cd58b91419 Stylish edits 2019-09-01 12:09:39 +00:00
Marcin Szamotulski
df0d3e4528 hoistOp - Op is an endo-functor of category of categories 2019-09-01 12:09:39 +00:00
Marcin Szamotulski
559f9fb404
README.md - some edits 2019-08-31 12:40:00 +02:00
Marcin Szamotulski
97cfd5c551 Updated README and CHANGELOG files 2019-08-31 10:35:21 +00:00
Marcin Szamotulski
1f20714c0a Added semigroup and monoid instances
Arr anc A are categories, and thus every endo-morphism object is
a monoid.
2019-08-31 10:35:21 +00:00
Marcin Szamotulski
08ee2a979b Free Arrows - various changes
Added:
* arrArr
* mapArr
* foldArr

Renamed:
* (:.:) as Cons (not exported)

Exported:
* Added Arr, Prod
2019-08-31 10:35:21 +00:00
Marcin Szamotulski
3746ef5d29 Efficient free arrow data type 2019-08-31 10:35:21 +00:00
Marcin Szamotulski
d88b444cfe Free.Internal - remove (:.:) constructor 2019-08-31 10:35:21 +00:00
Marcin Szamotulski
fd9dba5509 arrCat and mapCat
Renamed arrow to arrCat, since 'arrCat' is very like 'arr' for 'Arrows'.
'mapCat' is a smart constructor.
2019-08-31 10:35:21 +00:00
Marcin Szamotulski
ed310d4af7 Export Cat Id constructor
At times it is useful to be more explicit than
`id :: Category c => c a a`
2019-08-31 10:35:21 +00:00
Marcin Szamotulski
81df8c4abc Remove default-extensions from the cabal file
Add show-extensions haddock option.
2019-08-31 10:35:21 +00:00
Marcin Szamotulski
b1f3bda123 Move type aligned real time queues to an internal module 2019-08-31 10:35:21 +00:00
Marcin Szamotulski
4d0011df04
Updated README.md file 2019-08-31 10:19:44 +02:00
Marcin Szamotulski
20d61b2355
Efficient representation of a free category (#5)
* Efficient representation of free category

Using type aligned real time queues (Okasaki, 'Purely Functional Data
Structures') to represent catanable type allign lists (free categories).

Composition is O(1) and right fold is O(n), where n is number of
transitions.

* Bump version to 0.0.3

Make it compile on ghc802.

* Updated CI configuration
2019-08-31 08:12:21 +00:00
Marcin Szamotulski
ecc808dc7d
Stylistic changes 2019-08-24 10:28:08 +02:00
Marcin Szamotulski
875dcd99e9
Updated cabal file 2019-03-12 20:05:03 +00:00
Gabor Greif
2cdbb82c09 Proofreading (#3)
@ggreif thanks for proofreading!
2019-01-26 11:20:29 +01:00
Marcin Szamotulski
4ce35b64d8
Updated README.md and ChangeLog.md 2019-01-26 11:00:56 +01:00
Marcin Szamotulski
bb0e91b631
Rename: EffCategory, FreeEffCat 2019-01-26 10:53:06 +01:00
Marcin Szamotulski
7efa4c4430
Use callCabal2nix 2019-01-08 22:07:22 +01:00
Marcin Szamotulski
2cc5f7ac38
Install cachix from cachix.org 2019-01-06 15:38:40 +01:00
Marcin Szamotulski
02f90c2f63
Use nixox-18.09 in cricleci 2019-01-06 13:06:21 +01:00
Marcin Szamotulski
255d16547d
travis: ghc-862 2018-12-16 23:12:16 +01:00
Marcin Szamotulski
3159b1216e
nix: ghc802 build
Fix nixpkgs depending on ghc version.
2018-12-16 23:12:15 +01:00
Marcin Szamotulski
74492388fa
Update README 2018-12-16 23:12:15 +01:00
Marcin Szamotulski
20fdc8d189
Updated nix (ghc-8.6.2) 2018-12-16 23:12:15 +01:00
Marcin Szamotulski
786cb93890
LoginStateMachine example 2018-12-16 23:12:15 +01:00
Marcin Szamotulski
62d0bbe4fe
Lifting (#2)
* Initial LoginStateMachine implementation

* Nicer interface

* Lifting instance for (->) and Identity, liftKleisli function

* Added Control.Category.Lifting to free-algebras

* Reoder Lifting module

* Fixed haddoc documentation

* examples.cabal - base version

* reconfigure circle-ci

* Fixed error in GHC-8.6.1
2018-12-10 19:59:39 +01:00
Marcin Szamotulski
34d9b45c07
circleci: cachix-push command parameter 2018-11-11 13:18:14 +01:00
Marcin Szamotulski
d1c5c3ef80
Fixed typo in nix/nixpkgs.nix file 2018-11-11 13:15:03 +01:00
Marcin Szamotulski
2aa4d66f23
Added circleci config file 2018-11-11 12:51:26 +01:00
Marcin Szamotulski
adbb6c3550
Initial version 2018-11-03 17:52:30 +01:00
Marcin Szamotulski
f72b2e503f Updated free-algebras dependency 2018-10-27 12:26:44 +00:00
Marcin Szamotulski
3fdd610608 Free Arrow 2018-10-27 12:26:44 +00:00
Marcin Szamotulski
794e7397cb
ArrowZero and ArrowChoice instances 2018-10-24 10:33:04 +02:00
Marcin Szamotulski
93eafd738f
Added Arrow instances 2018-10-24 10:33:04 +02:00
Marcin Szamotulski
99771692da
Updated README and documentation 2018-10-23 22:15:11 +02:00
Marcin Szamotulski
de9bbe0b28
Added SSet and MSet instances 2018-10-23 16:45:24 +02:00
Marcin Szamotulski
278d1a4c60
Fixed cachix signing key 2018-10-23 14:02:08 +02:00
Marcin Szamotulski
5b2cc8e2b6
Build with ghc802 2018-10-22 23:46:22 +02:00
Marcin Szamotulski
87c3334051
Added Semigroup and Monoid instance for 'C f o o' 2018-10-22 17:00:55 +02:00
Marcin Szamotulski
6b9dfa1c0e
Compile with GHC 822 2018-10-22 17:00:35 +02:00
Marcin Szamotulski
f1f1c443eb
Simplified the module, added some documentation 2018-10-22 16:42:26 +02:00
Marcin Szamotulski
015de89f7e
Fixed travis.yml file 2018-10-22 12:04:05 +02:00