Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change UpdateParser to use Monad Transformers #171

Merged
merged 3 commits into from
Mar 28, 2024

Conversation

lispandfound
Copy link
Contributor

Small enhancement to the update parser interface, use monad transformers instead a custom monad implementation. This makes it easier to understand for people reading the code base for the first time, and also means we inherit all the typeclasses mtl and transformers already give ReaderT and Maybe. Provided end users are not using the UpdateParser constructor directly (i.e. they use mkParser instead) this is a completely transparent change.

@lispandfound lispandfound changed the title Update parser transformers Change UpdateParser to use Monad Transformers Mar 11, 2024
@lispandfound
Copy link
Contributor Author

In particular, I have tested that all the examples compile without changes using the new code. The example todo bot works identically to the todo bot on master. I haven't tried the game bot.

@swamp-agr swamp-agr merged commit 01f80a0 into fizruk:master Mar 28, 2024
8 checks passed
@swamp-agr
Copy link
Collaborator

This is a very good observation! Thank you for contribution! I have checked instances of ReaderT in advance (they are identical).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants