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

Draft rewrite rules for 069-coq-roadmap.md #70

Merged
merged 3 commits into from
Jul 19, 2023
Merged

Draft rewrite rules for 069-coq-roadmap.md #70

merged 3 commits into from
Jul 19, 2023

Conversation

TheoWinterhalter
Copy link

I'm not entirely sure about style so I did something. Please tell me whether this is what you expected or not.

@Zimmi48
Copy link
Member

Zimmi48 commented Jul 19, 2023

Thanks, @TheoWinterhalter! FWIW, in a recent private chat with @jfehrle, he was suggesting (and I agree) that explicating the main use cases would be really useful for readers who do not know about the feature, and to understand why this is an important feature which is on the roadmap. His example template was with rewrite rules:

It would be great to include a brief description of the user impact of each improvement (along the lines of "user-defined rewrite rules will make it possible/much easier to do , which has been a bottleneck for <something higher level and less technical that is readily understood; the real world impact>"

On the other hand, since there is already a CEP about rewrite rules, maybe a link to it would be sufficient.

In terms of technical details, I think this is also sufficient like this (referring to the CEP for additional detail / additional discussion).

@TheoWinterhalter
Copy link
Author

I tried to add a bit of that. :)

text/069-coq-roadmap.md Outdated Show resolved Hide resolved
@Zimmi48
Copy link
Member

Zimmi48 commented Jul 19, 2023

Thanks!

@Zimmi48 Zimmi48 merged commit 12029f9 into coq:coq-roadmap Jul 19, 2023
@TheoWinterhalter TheoWinterhalter deleted the patch-1 branch July 19, 2023 13:45
@@ -89,6 +89,12 @@ to add and remove items, to reflect the evolution of the project.

#### Rewrite rules

The goal is to add (unsafe) user-defined rewrite rules. This features allows users to add computation rules to axioms which can be useful for prototyping. It also allows for different kinds of computation rules with respect to what Coq currently permits: non-linearity, overlapping left-hand sides (*eg* one can write an addition on natural numbers that reduces on both sides: `0 + n` and `n + 0` both reducing to `n`).
Copy link
Member

@jfehrle jfehrle Jul 19, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"prototyping" isn't mentioned in the CEP (#50). It suggests that there are later steps to make something "final" or "production". Perhaps you could explain what you have in mind in the CEP with a brief explanation of those later steps?

What fraction of our users will be willing/able to use this feature for important projects if it's unsafe?

I assume prototyping is meant for users and not just Coq developers.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand why it should be mentioned in the CEP. These are just examples of what people want to do with rewrite rules: in particular we already have people using the fork of @yannl35133 to try out various type theories that are not otherwise encodable in Coq.

This use case has nothing to do with the status of rewrite rules.

It is true however, that the first instance we propose is something that is unsafe—in the sense that Coq may not terminate, or be incomplete for conversion if the user did not choose the right rewrite rules—and that the user must know that. To me this is the same as unsetting guard checking or using Type : Type, these are features used by actual people in actual projects even though they are not safe.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's that "prototyping" is unclear. As I said:

It suggests that there are later steps to make something "final" or "production".

What are those steps? Or is it a misleading choice of word? Can you clarify?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think there is a misunderstanding. A user may want to use rewrite rules for prototyping before they actually implement something, but it's up to the user so I don't have to explain the steps for this hypothetical user work.

@jfehrle
Copy link
Member

jfehrle commented Jul 19, 2023

@Zimmi48 FWIW, the rendering where you quote me above omitted "make it possible/much easier to do <some technical thing>". This '<' needed to have a backslash escape :-(

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.

3 participants