Suppose that I have a YAML entry like foo: bar
. Can I use yaml-cpp to rename the key foo
to buz
without having to copy all the content? In other words, I know that I can do this:
YAML::Node node = YAML::Load("foo:bar");
YAML::Node new_node;
new_node["buz"] = node["foo"];
However, this seems wasteful and I wonder if there is a built-in ability to just rename the key foo
?