1
1
mirror of https://github.com/coot/free-category.git synced 2024-11-22 16:22:05 +03:00
free-category/examples
Gabor Greif 963b3f1221 Tweaks
2020-10-19 18:39:42 +02:00
..
src Tweaks 2020-10-19 18:39:42 +02:00
CHANGELOG.md Lifting (#2) 2018-12-10 19:59:39 +01:00
examples.cabal Updated cabal files and ChangeLog.md file 2020-07-22 19:27:12 +02:00
LICENSE Lifting (#2) 2018-12-10 19:59:39 +01:00
README.md Fix Edwin's name 2020-10-19 18:39:42 +02:00
Setup.hs Lifting (#2) 2018-12-10 19:59:39 +01:00

Example State Machine using 'EffCat'

The example state machine is inspired by State Machines All The Way Down by Edwin Brady, 2017 https://www.youtube.com/watch?v=xq7ZuSRgCR4

It allows to login, access a secret token and logout. The secret token can only be accessed upon successful login. The implementation type checks this requirement.

Run quickcheck tests and an example program:

cabal run examples
+++ OK, passed 100 tests.

Provide a password:
123456
Provide a password:
password
secret: Hello saylor!