当我做 :
var root = new YamlMappingNode();
var doc = new YamlDocument(root);
root.Add("one", "two");
var stream = new YamlStream(doc);
var buffer = new StringBuilder();
using (var writer = new StringWriter(buffer))
{
stream.Save(writer, false);
var t = buffer.ToString();
}
我得到:
one: two
...
为什么文件末尾有3个点?