var.toString
string toString() const @safeConvert the stored value to a human-readable string.
Formatting rules:
- Scalars use
std.conv.toformatting (e.g.,1,true). Type.STRINGreturns the raw string (no quotes) at the top level.Type.ARRAYandType.OBJECTare rendered in a compact, JSON-like form:- Arrays:
[elem1,elem2,...](elements are recursively formatted; strings are quoted with escapes). - Maps:
{"key":value,...}with keys sorted lexicographically for deterministic output. - A recursion guard is applied to avoid runaway printing; deeply nested content may be replaced with
null.