import mir.timestamp: Timestamp; import mir.format: stringBuf; import mir.test; auto someMatrix = [ [3.0.CsvAlgebraic, 2.CsvAlgebraic, true.CsvAlgebraic, ], ["str".CsvAlgebraic, "2022-12-12".Timestamp.CsvAlgebraic, "".CsvAlgebraic, null.CsvAlgebraic], [double.nan.CsvAlgebraic, double.infinity.CsvAlgebraic, 0.0.CsvAlgebraic] ]; someMatrix.serializeCsv.should == "3.0,2,TRUE\nstr,2022-12-12,\"\",\nNAN,+INF,0.0\n";
CSV serialization function.