aspect-macros 0.1.0

Procedural macros for aspect-oriented programming in Rust
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
//! Parsing utilities for aspect macro attributes.

use syn::{Expr, Result};

/// Information about the aspect to apply.
pub struct AspectInfo {
    /// The expression that evaluates to the aspect instance
    pub aspect_expr: Expr,
}

impl AspectInfo {
    /// Parse aspect information from the attribute syntax.
    pub fn parse(aspect_expr: Expr) -> Result<Self> {
        Ok(Self { aspect_expr })
    }
}