-
Notifications
You must be signed in to change notification settings - Fork 297
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
Linting tools #687
Comments
@spl, @robertylewis, @rwbarton, @digama0, @johoelzl any thoughts? |
It all sounds good to me! |
Another thing that can be detected: duplicate lemmas |
Would you recommend detecting duplicata via syntactic equality modulo variable renaming? |
I have no clue what is best... if the versions are next to each other, and one has explicit arguments and the other doesn't, maybe it is on purpose. But if they are in different files... it probably is a mistake. So we need some heuristics... |
I just built a tool for detecting spurious imports using @digama0's parser: https://github.com/cipher1024/olean-rs I used it to remove quite a few unneeded imports: #878 |
Is there any documentation? |
not much for now except when you call
|
What I've been doing in |
... now I'm realizing that that doc is wrong :/ |
It should be
|
I had forgotten about this issue. Some of this is now in the "internal" linter, and perhaps more could be added (#1924). |
The goal is to sanitize the mathlib code base but also, the code base of any project depending on it.
Here is a short list of code smells that can be detected automatically:
These could be implemented by a combination of @digama0's olean parser and some Lean meta programming.
The text was updated successfully, but these errors were encountered: