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

Dead branch in proc macro triggers clippy::missing_panics_doc #3594

Open
paolobarbolini opened this issue Nov 6, 2024 · 1 comment · May be fixed by #3595
Open

Dead branch in proc macro triggers clippy::missing_panics_doc #3594

paolobarbolini opened this issue Nov 6, 2024 · 1 comment · May be fixed by #3595
Labels

Comments

@paolobarbolini
Copy link
Contributor

Bug Description

This panic 1 is causing all uses of the query! macros to trigger clippy::missing_panics_doc. This is very annoying because we want to warn on panics at the project level, but then we have to allow it in each usage of the query macros.

Minimal Reproduction

Use sqlx::query_file_as with #![deny(clippy::missing_panics_doc)]

Info

  • SQLx version: 0.8.2
  • SQLx features enabled: postgres
  • Database server and version: 17.0
  • Operating system: Arch Linux
  • rustc --version: rustc 1.84.0-nightly (b8c8287a2 2024-11-03)

Footnotes

  1. https://github.com/launchbadge/sqlx/blob/82d332f4b487440b4c2bd5d54a5f17dcc1abc92c/sqlx-macros-core/src/query/args.rs#L92

@humb1t
Copy link

humb1t commented Nov 25, 2024

It's also affecting https://rust-lang.github.io/rust-clippy/master/index.html#panic
Would be nice to not trigger that, thanks @paolobarbolini

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

Successfully merging a pull request may close this issue.

2 participants