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

Replace ExactDsl by RaiseDsl #15

Closed
CLOVIS-AI opened this issue May 20, 2023 · 0 comments
Closed

Replace ExactDsl by RaiseDsl #15

CLOVIS-AI opened this issue May 20, 2023 · 0 comments

Comments

@CLOVIS-AI
Copy link

CLOVIS-AI commented May 20, 2023

Hi! Sorry for not being very active the past few weeks. I'm currently catching up with everything that happened.

First, I'm impressed by how concise the result is. It's a single line longer than the current "use require in the constructor" idiom, and barely more verbose.

I've played a bit with the examples, and I'm not sure having a ExactDsl annotation is necessary. Since we decided to name the predicate function ensure for coherence with the rest of Arrow, I think we should use RaiseDsl instead.

Here is a simple example where I use both ensure. To me, this risks being confusing to users—after all, if IntelliJ highlights them differently, that means they do not relate to the same DSL, that's the entire point of DSL coloring—whereas we expect this to be completely legitimate code.

Screenshot_20230520_231446

I don't think there is a valid use-case for nesting exact DSLs, so the annotation is only useful as documentation/coloration anyway. What do you think?

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

No branches or pull requests

2 participants