Skip to content

Table arrays containing primitive arrays unnecessarily serialize inline. #72

@Evan-Walden-ATS

Description

@Evan-Walden-ATS

The following TOML file:

[[table_array]]
primitive_list = [4, 5, 6]

When run through the functions Toml.ToModel & Toml.FromModel as follows:

var toml = "[[table_array]]\nprimitive_list = [4, 5, 6]";

var model = Toml.ToModel(toml);
var tomlOut = Toml.FromModel(model);

Results in the following output:

table_array = [{primitive_list = [4, 5, 6]}]

I believe this may be a bug, as it appears that the serialization code otherwise prefers to use the non-inline style wherever possible.

Metadata

Metadata

Assignees

No one assigned

    Labels

    PR welcomeUser contribution/PR is welcomebugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions