LogoMist

Attributes

Inner and outer attributes for modules, items, and metadata.

Inner attributes apply to the containing module:

#![allow(unused_variables)]

Outer attributes apply to the next item:

#[derive(Debug, Clone)]
struct Point {
    i32 x;
    i32 y;
}

#[test]
void my_test()
{
    assert_eq!(1, 1);
}

Attribute syntax:

  • #[path]
  • #[path = literal]
  • #[path(item1, item2, ...)]