dynomite icon indicating copy to clipboard operation
dynomite copied to clipboard

Make the derivation of attribute mapping handle raw identifiers (`r#…`) properly

Open jakubadamw opened this issue 4 years ago • 0 comments

This fixes an issue, whereby dynomite would not treat raw identifiers (r#…) properly as it would include the syntactical r# prefix in the serialized attribute values.

For example, the value of the following enum:

#[derive(Attribute, Clone, Copy, Debug, PartialEq)]
pub enum EnumWithRawFieldNameIdentifier {
    r#VariantName,
}

would be serialized as "r#VariantName".

With this fix it will be serialized as "VariantName", as, I think, expected.

jakubadamw avatar Jan 18 '22 17:01 jakubadamw