YamlDotNet
YamlDotNet copied to clipboard
YamlDotNet is a .NET library for YAML
This PR intended to fix #991. **What's changed in this PR** - Replace `formatter.FormatNumber(object value);` call to `ToString("G", CultureInfo.InvariantCulture)`. - It's required to serialize special symbols (Nan/PositiveInfinite/NegativeInfinite) to JSON compatible...
If I serialize an integral double value (e.g `1.0`), it becomes a string. EDIT: From debugging, it looks like `NumericRegex` in `JsonEventEmitter.cs` is wrong. It does not match against single-digit...
https://github.com/aaubry/YamlDotNet/blob/7923dd8e600f7fea7710f3b45f3fadcfa1aa589c/YamlDotNet/Serialization/Utilities/TypeConverter.cs#L77 I guess this is the bug that breaks my `FromYaml` where I'm lacking specific type information: https://github.com/riezebosch/YamlDotNetDataReader/blob/main/YamlDotNetDataReader/DataReaderTypeConverter.cs#L27 Because it nows deserializes as a culture dependant object and incorrectly deserializes...
**Describe the bug** When serialize data to JSON. Some data are serialized as unexpected representation. **1. Serialized JSON data of `floating number` that contains `Exponential Notation` is serialized as `string`.**...
This PR intended to optimize performance for number deserialization by changing Parse to `TryParse` method. It's discussed at https://github.com/aaubry/YamlDotNet/pull/794 Additionally this PR fix `double` value deserialization problems that are found...
Common parts from ReadablePropertiesTypeInspector and WritablePropertiesTypeInspector are extracted to PropertiesTypeInspector and more changes to support #984: - virtual method PropertiesTypeInspector.CreateProperty - public property ReflectionPropertyDescriptor.PropertyInfo
Small improvements again when building against latest NET 9 SDK.