You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
//! Some docs here#![cfg_attr(bootstrap, doc = "xxx")]#![cfg_attr(debug_assertions, stable(feature = "rust1", since = "1.0.0"))]
Output
//! Some docs here#![cfg_attr(bootstrap, doc = "xxx")]#![cfg_attr(debug_assertions, stable(feature = "rust1", since = "1.0.0"))]
Expected output
//! Some docs here#![cfg_attr(bootstrap, doc = "xxx")]#![cfg_attr(debug_assertions, stable(feature = "rust1", since = "1.0.0"))]
I see here why rustfmt did this - it thinks that all cfg_attr attributes should be grouped together. But this doesn't make sense in the semantic context of the program: cfg_attr(doc) is a doc-comment and should be grouped with other doc-comments. See rust-lang/rust#80181 (comment) for a more realistic example.