You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
use ron::Error;use serde::{Deserialize,Serialize};#[derive(Serialize,Deserialize,PartialEq,Eq,Debug)]#[serde(rename = "Hello+World")]structRawStruct{#[serde(rename = "ab.cd-ef")]field:bool,}#[test]fntest_raw_identifier_roundtrip(){let val = RawStruct{field:true};let ser =
ron::ser::to_string_pretty(&val, ron::ser::PrettyConfig::default().struct_names(true)).unwrap();assert_eq!(ser, "r#Hello+World(\n r#ab.cd-ef: true,\n)");// Fails with an error that "Hello+World" was expected but "Hello+World" was foundlet de:RawStruct = ron::from_str(&ser).unwrap();assert_eq!(de, val);}
The text was updated successfully, but these errors were encountered:
The text was updated successfully, but these errors were encountered: