-
Notifications
You must be signed in to change notification settings - Fork 11
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 a "statement use" option #123
Conversation
That's very nice! Definitely I'll apply it for axiom minimizations (this is useful as well for activities like metamath/set.mm#3431, because I needed to list all theorems using Thank you so much for this work! |
src/main.rs
Outdated
c == ',' || (c.is_ascii() && c.is_alphanumeric()) || c == '-' || c == '_' || c == '.' | ||
}) | ||
.then_some(()) | ||
.ok_or("Expected list of Metamaths labels".to_string()) |
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.
.ok_or("Expected list of Metamaths labels".to_string()) | |
.ok_or("Expected list of labels".to_string()) |
I don't think we need to specify this, we don't usually qualify the term elsewhere. We could clarify the grammar in the error message if you think it helps though.
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.
This is also a good place to use glob patterns, if we have them (I think david had an implementation in another PR?) (We can do this in a follow up PR if you prefer)
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.
We did not keep the glob patterns in the final solution. I think eventually the best is to first split the project into library/command line tool, and then only include the glob library of choice into the latter. So yes, let's keep that for later.
I executed the command |
Yes, that's not ideal. How about changing the parameters so that
|
Sounds good, I like it. |
One for the file and one for the label list.
I've committed an update which does that. I could not use the validator function because it would be applied both on the file path and the label list, so I moved it into our own code. |
Co-authored-by: Mario Carneiro <[email protected]>
Co-authored-by: Mario Carneiro <[email protected]>
As suggested by @GinoGiotto in a comment in #3399, this adds an option to get direct of indirect usage of theorems, given by the list of their labels.