Skip to content

Support nullptr_t #39

@Chlumsky

Description

@Chlumsky

I have realized that when skipEmptyFields is true, there is no way to output null into the JSON. A possible solution for this very niche use case would be to add a NullType class that would be used for std::nullptr_t and would always serialize as null and when parsed, it would just throw TYPE_MISMATCH if the value is anything else. I would like to add this mainly because it's a pretty elegant use of the available nullptr_t type.

Metadata

Metadata

Assignees

No one assigned

    Labels

    code-generationInvolves generation of parser / serializer codeminorA minor issue

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions