-
Notifications
You must be signed in to change notification settings - Fork 970
Open
Labels
C-bugCategory: this is a bug; use also I-* labels for specific bug kinds, e.g. I-non-idempotency or I-ICECategory: this is a bug; use also I-* labels for specific bug kinds, e.g. I-non-idempotency or I-ICEgood first issueIssues up for grabs, also good candidates for new rustfmt contributorsIssues up for grabs, also good candidates for new rustfmt contributors
Description
If you format...
#[allow()]
unsafe extern "C" {
#[allow()]
pub fn foo(#[allow()] arg: *mut u8, #[allow()]...);
}Then it will format into
#[allow()]
unsafe extern "C" {
#[allow()]
pub fn foo(#[allow()] arg: *mut u8, ...);
}(The choice of attribute seems irrelevant, I've used allow because it compiles in any position).
Note that this position is explicitly documented at https://doc.rust-lang.org/nightly/reference/attributes.html#r-attributes.allowed-position
Metadata
Metadata
Assignees
Labels
C-bugCategory: this is a bug; use also I-* labels for specific bug kinds, e.g. I-non-idempotency or I-ICECategory: this is a bug; use also I-* labels for specific bug kinds, e.g. I-non-idempotency or I-ICEgood first issueIssues up for grabs, also good candidates for new rustfmt contributorsIssues up for grabs, also good candidates for new rustfmt contributors