alloy_sol_macro_input

Trait ContainsSolAttrs

Source
pub trait ContainsSolAttrs {
    // Required method
    fn attrs(&self) -> &[Attribute];

    // Provided method
    fn split_attrs(&self) -> Result<(SolAttrs, Vec<Attribute>)> { ... }
}
Expand description

Trait for items that contain #[sol(...)] attributes among other attributes. This is usually a shortcut for SolAttrs::parse.

Required Methods§

Source

fn attrs(&self) -> &[Attribute]

Get the list of attributes.

Provided Methods§

Source

fn split_attrs(&self) -> Result<(SolAttrs, Vec<Attribute>)>

Parse the #[sol(...)] attributes from the list of attributes.

Implementations on Foreign Types§

Source§

impl ContainsSolAttrs for File

Source§

fn attrs(&self) -> &[Attribute]

Source§

impl ContainsSolAttrs for ItemContract

Source§

fn attrs(&self) -> &[Attribute]

Source§

impl ContainsSolAttrs for ItemEnum

Source§

fn attrs(&self) -> &[Attribute]

Source§

impl ContainsSolAttrs for ItemError

Source§

fn attrs(&self) -> &[Attribute]

Source§

impl ContainsSolAttrs for ItemEvent

Source§

fn attrs(&self) -> &[Attribute]

Source§

impl ContainsSolAttrs for ItemFunction

Source§

fn attrs(&self) -> &[Attribute]

Source§

impl ContainsSolAttrs for ItemStruct

Source§

fn attrs(&self) -> &[Attribute]

Source§

impl ContainsSolAttrs for ItemUdt

Source§

fn attrs(&self) -> &[Attribute]

Implementors§