Skip to content

#[expect(..)] not supported on function arguments #97650

Closed
@Jarcho

Description

@Jarcho

This isn't used by many lints, but clippy does have a few. This is the only location I've noticed, but I haven't checked everywhere.

fn f(
    #[expect(clippy::ptr_arg)] _x: &Vec<u32>,
) {}

I expected to see this happen: Nothing

Instead, this happened:

error: allow, cfg, cfg_attr, deny, forbid, and warn are the only allowed built-in attributes in function parameters

cc #54503

Metadata

Metadata

Assignees

Labels

C-bugCategory: This is a bug.F-lint_reasons`#![feature(lint_reasons)]`

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions