We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
env!
1 parent 5a6c4d7 commit a147372Copy full SHA for a147372
clippy_lints/src/strings.rs
@@ -328,7 +328,7 @@ impl<'tcx> LateLintPass<'tcx> for StringLitAsBytes {
328
{
329
// Don't lint. Byte strings produce `&[u8; N]` whereas `as_bytes()` produces
330
// `&[u8]`. This change would prevent matching with different sized slices.
331
- } else {
+ } else if !callsite.starts_with("env!") {
332
span_lint_and_sugg(
333
cx,
334
STRING_LIT_AS_BYTES,
0 commit comments