-
Notifications
You must be signed in to change notification settings - Fork 3
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
Unused function parameter detection fails in cases it shouldn't #10
Comments
Wrapping an argument in |
In the first example, the problem is caused by how Semgrep parses the list comprehension. If you write only the comprehension in a file (
There is no information about the iteration variable or the iterator. So there's no way to know that The second example (with And the last one is again a parsing problem. Semgrep doesn't think the syntax is correct. I'm not sure if the problem comes from the Julia tree-sitter or from the generic AST generated by Semgrep. |
Updates:
|
will cause
semgrep
to error with the current rules sayingb
is unused.Similarly,
Val
types used to dispatch (or any::Type{SomeType}
) arguments cause unused parameter errors:this will generate an error saying
::Val{true}
is unused.The text was updated successfully, but these errors were encountered: