Is there any information available on how the Maxon DataTypes implement ToString()
's FormatStatement?
And secondly, a maxon::Data
with nullptr
as argument gives a different result than an unconfigured FormatStatement
argument. Is this intended behaviour?
// Store values
template <typename T>
void CreateAttribute(maxon::String name, T value)
{
_attributes.Set(name, value);
}
// ........
myElement->CreateAttribute("MyAttributeName"_s, 23.0);
// To print them:
maxon::String buf;
maxon::FormatStatement fs;
buf += " "_s + attrib.first.ToString(nullptr) + "=\""_s + attrib.second.ToString(nullptr) + "\""_s; // This gives another result than
//buf += " "_s + attrib.first.ToString(nullptr) + "=\""_s + attrib.second.ToString(fs) + "\""_s
DiagnosticOutput("@", buf);