Version Information
From Nuget: Hocon and Hocon.Configuration 2.0.3
(Reproduced on dev, (482a9c1), with failing tests, here: ClaytonHughes@0e55a7c)
Describe the bug
When configurations are serialized, backslashes are not escaped. This means a round-trip serialization of a Config will not succeed.
To Reproduce
Steps to reproduce the behavior:
- Have a backslash in your Config (e.g. by parsing a string with an escaped backslash)
- Serialize it - note the output is incorrect (backslashes are not escaped)
- Parse the serialization - note the tokenizer exception because of the invalid input
Expected behavior
Configurations serialize into valid Json/HOCON (backslashes are escaped).
Actual behavior
Configurations do not escape backslashes, producing (likely) invalid Json/Hocon.
Environment
net461, netcoreapp2.1
Version Information
From Nuget: Hocon and Hocon.Configuration 2.0.3
(Reproduced on dev, (482a9c1), with failing tests, here: ClaytonHughes@0e55a7c)
Describe the bug
When configurations are serialized, backslashes are not escaped. This means a round-trip serialization of a Config will not succeed.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Configurations serialize into valid Json/HOCON (backslashes are escaped).
Actual behavior
Configurations do not escape backslashes, producing (likely) invalid Json/Hocon.
Environment
net461, netcoreapp2.1