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

Add Terraform equivalence on automatic type conversions #6898

Closed
rc-mattschwager opened this issue Jan 20, 2023 · 0 comments · Fixed by #6917
Closed

Add Terraform equivalence on automatic type conversions #6898

rc-mattschwager opened this issue Jan 20, 2023 · 0 comments · Fixed by #6917

Comments

@rc-mattschwager
Copy link

Is your feature request related to a problem? Please describe.

Terraform supports automatic type conversions between strings, ints, and bools: https://developer.hashicorp.com/terraform/language/expressions/types#type-conversion. E.g. "42" and 42, "true" and true.

Describe the solution you'd like

It would be helpful if Semgrep automatically supported these type equivalences so I don't have to manually specify separate cases in rules. Here's a link that exhibits the behavior: https://semgrep.dev/playground/s/D0Kj.

Describe alternatives you've considered

Manually specifying the equivalences

Use case
What will this feature enable for you?

Additional context
Add any other context or screenshots about the feature request here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging a pull request may close this issue.

3 participants