-
Notifications
You must be signed in to change notification settings - Fork 47
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
Add the let* monadic notation #96
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For compatibility, please create a separate module (e.g. MonadLetNotation
), so that importing MonadNotation
doesn't introduce two styles of notations at the same time.
Sorry, I misunderstood your comment on the issue. I was not sure how to proceed, so I propose two approach:
I personally prefer the latter, and it does not break the previous interface afaict. What do you think? |
Thanks! The latter with |
The failure with the CI was due to a commit I had added which was breaking old Coq version (declaring the scope). I have removed it and now it appears that it works fine. I should probably squash the two commits together if you prefer the approach with the base module (I do too! (: ). I think it would probably be wise to add some kind of test case too, right? |
Yes we could add some |
I think we are good to go now! |
Inspired by the notation introduced by OCaml 4.08, we propose to introduce a new notation following the same principle. let* x := p in q is strictly equivalent to x <- p;; q The former can be made available by importing the newly introduced [MonadLetNotation]. Loading this module does not provide the arrow-based notation, which can still be made available by importing the [MonadNotation] module as before.
Closes #95
Inspired by the notation introduced by OCaml 4.08, we propose to
introduce a new notation following the same principle.
is strictly equivalent to