Derive Macro simics::IntoAttrValueList

source ·
#[derive(IntoAttrValueList)]
{
    // Attributes available to this derive:
    #[attr_value]
}
Expand description

Derive Macro for implementing conversion into an AttrValue list, where each struct field’s value is an entry in the heterogeneous list.

§Arguments

At the field level (i.e. on each field of a struct deriving this attribute), the following attributes are supported:

  • #[attr_value(skip)] - Do not include this field in the conversion.
  • #[attr_value(fallible)] - If the field type does not implement Into<AttrValue>, use its implementation of TryInto<AttrValue> instead. Whether this flag is necessary cannot be automatically determined by this macro, so it must be specified manually.