-
-
Notifications
You must be signed in to change notification settings - Fork 510
Open
Description
Describe the bug
YAML 1.1 allows to have underscore in number representations, like 123_456 (int) and 123_456.78 (float).
However, this seems partially supported in YamlDotNet.
Underscore is supported when a tag (!!int or !!float) is specified. But when AttemptingUnquotedStringTypeDeserialization is turned on while the tag is missing, the type is not properly inferred.
To Reproduce
Please check this fiddle: https://dotnetfiddle.net/uL0fls
I feel the regular expression here is not sufficient: https://github.com/aaubry/YamlDotNet/blob/master/YamlDotNet/Serialization/NodeDeserializers/ScalarNodeDeserializer.cs#L356
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels