Back to Rust Analyzer

Highlight Attributes

crates/ide/src/syntax_highlighting/test_data/highlight_attributes.html

2026-05-04402 B
Original Source
#[allow(dead_code)]
#[rustfmt::skip]
#[proc_macros::identity]
#[derive(Default)]
/// This is a doc comment
// This is a normal comment
/// This is a doc comment
#[derive(Copy)]
// This is another normal comment
/// This is another doc comment
// This is another normal comment
#[derive(Copy, Unresolved)]
// The reason for these being here is to test AttrIds
enum Foo {
    #[default]
    Bar
}