Skip to content

Parsing result of numbers depends on allownan #397

@hhaensel

Description

@hhaensel

When allownan = true all numbers are parsed as Float64

julia> JSON.parse("1")
1

julia> JSON.parse("1", allownan = true)
1.0

julia> JSON.parse("""[1,2,3]""")
3-element Vector{Any}:
 1
 2
 3

julia> JSON.parse("""[1,2,3]""", allownan=true)
3-element Vector{Any}:
 1.0
 2.0
 3.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions